问题描述
尝试使用GA API for Java来获取数据,如开发指南.
Trying to get data using GA API for java like it's described in the devguide.
尺寸:
-
ga:pagePath
-
ga:date
-
ga:country
-
ga:hostname
-
ga:userType
ga:pagePath
ga:date
ga:country
ga:hostname
ga:userType
指标:
-
ga:pageviews
-
ga:sessions
-
ga:users
-
ga:uniquePageviews
-
ga:bounceRate
-
ga:pageValue
-
ga:exitRate
ga:pageviews
ga:sessions
ga:users
ga:uniquePageviews
ga:bounceRate
ga:pageValue
ga:exitRate
我要查询一个日期,max-result = 10000
.结果超过1万行,因此我正在使用start-index
循环查询.
I'm querying for a single date, max-result = 10000
. There are more than 10k rows in result, so I'm querying in a loop using start-index
.
该查询的问题在于,最终数据用户数约为会话数的3倍.当我进行更简单的查询(ga:users
,ga:sessions
在同一日期被ga:date
断开)时,配给似乎有效-users/sessions = 0.8
The problem with that query is that in the resulting data number of users is ~3 times greater than number of sessions. When I'm making a simpler query (ga:users
, ga:sessions
broken by ga:date
for the same date) the ration seems valid -- users/sessions = 0.8
源代码可在存储库中找到
关于如何通过更复杂的查询获得有效用户的任何想法?
Any ideas on how to get valid users count with that more complex query?
推荐答案
会话(GA中的奇数指标)仅在会话的首次匹配(即着陆页)上进行计数.在查看页面级数据时,如果某个页面不是目标页面,那么看到0次具有许多页面浏览量或用户的会话就不会感到惊讶.
Sessions (an odd metric in GA) are only counted on the first hit of the sessions i.e. the landing page. When viewing page-level data, if a page is not a landing page, do not be surprised to see 0 sessions with many pageviews or users.
如果要对此进行详细说明,请阅读: http://help.analyticsedge.com/googleanalytics/misunderstood-metrics -sessions-for-pages/
If you want a detailed explanation about this, read:http://help.analyticsedge.com/googleanalytics/misunderstood-metrics-sessions-for-pages/
这篇关于提取分页结果时,Analytics API返回错误的用户计数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!