维度关系不正确的Google Analytics(分析)跟踪事件

安东尼·雷蒙多

我试图跟踪一个具有3个维度(用户ID,小部件ID,帖子ID)的事件。每个点击事件必须在其自己的行中包含唯一的帖子ID,用户ID和小部件ID,以便我可以跟踪每个帖子的点击次数。附加:所有尺寸均设置为“用户”范围。

ga('send', 'event', 'widget', 'click', 'uwp', 
                        {
                            'dimension1': $user_id,
                            'dimension2': $widget_id,
                            'dimension3': $post_id
                        }
                    );

我稍后使用报告API进行查询。

$result = Analytics::query(
                $start_date,
                $end_date,
                'ga:totalEvents',
                array(
                    'dimensions' => 'ga:dimension3,ga:pagePath,ga:date,ga:eventAction',
                    'sort'       => '-ga:date',
                    'filters'    => 'ga:eventAction==click;ga:eventLabel==uwp;ga:dimension1=='.$user->id,
                    'max-results'=> '100'
                ));

结果不正确,所有点击均被捆绑为1个维度,即维度3为发布ID。例)如果我单击ID为30的帖子(dimension3设置为30)和ID为10的帖子,则会报告ID 30的帖子获得2次点击或某些较旧的ID进行2次点击。

Google Analytics Dashbaord选择: 在此处输入图片说明在此处输入图片说明

As you can see from the pick i have 1 row with post id of 2 and 7 clicks, yet i sent events with many different post ids. (dimension3 == post id).

Andy

The problem here is that you are setting all of these dimensions to have a scope of user. Because of this, each dimension can only have one value per user. This is fine for the user id dimension, but for a dimension like post id, this is likely incorrect. Presumably, a user can view many post ids. Setting post id to user scope will cause the post id value to be overwritten with the latest post each time a new post is seen (which is why only one value is appearing in your report). You'll instead want to set post id to have a scope of hit, which will allow a different value to be sent on each event hit.

You can change the scope via the interface.

阅读有关自定义维度范围的更多信息

本文收集自互联网,转载请注明来源。

如有侵权,请联系 [email protected] 删除。

编辑于
0

我来说两句

0 条评论
登录 后参与评论

相关文章

Google Analytics(分析)跟踪出站事件

Google Analytics(分析)事件跟踪问题

Google Analytics(分析)跟踪未配置的事件

Google Analytics(分析)通用事件跟踪

UIButton事件跟踪Google Analytics(分析)(快速)

链接上的Google Analytics(分析)事件跟踪

Google Analytics(分析)事件跟踪未显示

跟踪事件的Google Analytics(分析)angularjs指令

Google Analytics(分析),出站事件跟踪

Google Analytics(分析)中没有事件跟踪

点击表单提交后在Google Analytics(分析)中跟踪事件

针对单个用户的Google Analytics(分析)事件跟踪

未跟踪Google Analytics(分析)下载事件目标

Google Analytics(分析):事件跟踪与虚拟综合浏览量

Google Analytics(分析)页面视图javascript与事件跟踪javascript

iOS上的Google Analytics(分析):未跟踪事件

Google Analytics(分析)事件跟踪-不起作用

如何设置appVersion进行Google Analytics(分析)事件跟踪

未显示Google Analytics(分析)事件跟踪(gtag)

Onclick事件跟踪Google Analytics(分析)Wordpress Visual Composer插件

Google Analytics(分析)跟踪事件不起作用

Google Analytics(分析)事件跟踪不起作用

Google Analytics(分析)事件跟踪不起作用

通用Google Analytics(分析)事件跟踪不起作用

Google Analytics(分析)自定义事件跟踪/目标不适用于新的Google Analytics(分析)跟踪代码

Google跟踪代码管理器中的Google Analytics(分析)事件跟踪

Google Analytics(分析)事件跟踪无法跟踪两次或多次

Google Analytics(分析)/跟踪代码管理器-事件跟踪-我很困惑

为什么我的Google Analytics(分析)号召性事件跟踪代码无法跟踪?