博文

目前显示的是标签为“google analytics”的博文

Google Analytics的account结构

图片
Nothing is better than a picture: Account: Top-most level of organization Property:  Website, mobile app, blog, etc Property is the level of tracking code ID. Property has one un-filtered profile Profile: Access point for report A defined view of data from a property Once profile get deleted, the data of this profiel get lost forever. Users: User or administrator

理解 Google Analytics中的 Bounce Rate 和 Exit Rate

Bounce Rate: Bounce rate is the percentage of visits that go only one page before exiting a site. Bounce rate calculation is only based on visits that start with that page.  Ex: There are 3 visits: 1. Page A->B->C->Exit 2. Page B->A->C->Exit 3. Page A->Exit The bounce rate for A is 50% (Not 33%, because visit No.2 does not involve in page A's bounce rate calculation) Exit rate is the percentage of visits that exit from the particular page. Follow above example: The exit rate for A is 33% (A involve in 3 sessions, and only 1 session end from A) The exit rate for B is 0% (B involve in 2 sessions, and no session end from B)

Google analytics event tracking (web tracking)

is a method in ga.js record user-interaction with web element attach method call to paticular UI element pageview calculation unaffected Setup: _trackEvent(category, action, opt_label, opt_value, opt_noninteraction) Ex: _gaq.push('_trackEvent','Videos','Download','Gone with wind'); Category: required, appear in event report the group name of the objects we want to track Actions: In report actions are listed independently from parent category Unique event is affected by unique action name unique event per category-action pair difference in "top action" and "category action" report Labels: not required can provide additional dimension in report Values: not required, integer value, NOT negtive value Non-interaction events: If set this attribute to True, means this user-interaction does not counted as an interaction on this page. So if the visit ends from this page, the page is considered "boun...

Google analytics custom campaigns tracking

无法查看这则摘要。请 点击此处查看博文。

Google analytics custom variables 笔记

Custom variable: Is a name-value pair Custom variables can help to define additional segments There are 3 levels in GA's visitor interaction model visitor session page _setCustomVar(index, name, value, opt_scope) index - slot 1 to 5, required opt_scope - 1,2,3 default to page scope 3 You can _deleteCustomVar(index) to remove a CV Call _setCustomVar() before pageView or event Page level: A single pageView, event, or transaction call Variable slots can be reused on one page, but only the last one will apply in that case For any single page, only up to 5 CV can be used Session level: Apply to the current session - decided by cookies Last set value in the session scope CV win If use the same slot, session scoped CV will override page scoped CV(see note 1) For any given session, up to 5 CV can be used Visitor level: Current and future session for the lift of visitor cookies Last set value in the last session win Up to 5 Note 1: When use...

Google analytics advanced segments + Dimension and metrics

Advanced segments: Isolate and analyze specific kind of traffic Different with filtered profile Historical data can use segment Can compare or view multiple segments Filters is better if you always want to have a filtered traffic Segments can apply to filtered profile data Filtered profile data can work with user's view permission, on the other hand, permission can not control advanced segment Dimension and metrics: Dimension for describe data while metrics for measure data There are certain combinations of dimensions and metrics for custom report

Google analytics E-commerce tracking

Enable E-commerce on profile include or not include cross-domain tracking Add eCommerce tracking on web transaction object - _addTrans() transaction item - _addItem() submit transaction - _trackTrans() Guidelines Unique SKU for each item added Price is without currency, should convert in own code before submit to analytics Recommended to call _trackPageView on order confirmation page You can set local currency  Issues You can reverse an transaction by using negative value eCommerce tracking allow segments and custom segments Those are not the same as filters They apply the on final data

Google analytics tracking code

Install tracking code: Use new asynchronous code Wait 24h for setting to take effect Recommended to put script at bottom of HTML HEAD Specialized tracking: Download links _trackPageView() -virtual page view _trackEvent() Outbounds links _trackEvent() +  depay outbound link by JS Redirections Flash  virtual page view - possibility to get visits inflating track event Tracking across domains: Add links Multiple tracking code on one page is not supported Search engine robot normally not active JS, so their visits are not tracked Conversion triggered when goals reached: Goals URL destination goal + funnels(steps to follow in goals) time on site page per visit Combine goals and funnels URL destination goal: Fixed URL E-commerce - leave goal value blank, since they are tracked by code URL parameter - head match or regEx Same URL for different steps - use track code to create virtual page view

在本地服务器测试你的Google Analytics设置

Google Analytics 允许你自定义你的tracking code。 如果你在你的本地服务器localhost上测试GA你会发现你的tracking event 没有被发送到Google。那么如何在你的设置发布到Production服务器之前测试你的GA设置呢? 最简单的办法莫过于增加以下代码到你的tracking代码: var _gaq = _gaq || [ ] ; _gaq. push ( [ "_setAccount" , "UA-1234-1" ] ) ; _gaq. push ( [ "_setDomainName" , "none" ] ) ; _gaq. push ( [ "_trackPageview" ] ) ; 其中关键的部分在第三行  _gaq. push ( [ "_setDomainName" , "none" ] ) ; 这样你就会发现tracking request被发送到google了。  需要注意的是在第一次设置好后GA通常需要大约24小时来接受你的数据。不过你可以使用real-time tracking 来确认你的GA设置在localhost上是正确的。