在Universal Analytics中启用受众特征和兴趣报告 [英] Enable Demographics and Interests reports in Universal Analytics

查看:93
本文介绍了在Universal Analytics中启用受众特征和兴趣报告的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想通过Universal Analytics跟踪代码启用受众特征和兴趣报告。



我的网站生成的跟踪代码如下所示:

 < script> 
(function(i,s,o,g,r,a,m){i ['GoogleAnalyticsObject'] = r; i [r] = i [r] || function(){
(i [r] .q = i [r] .q || [])。push(arguments)},i [r] .l = 1 * new Date(); a = s.createElement(o),
m = s.getElementsByTagName(o)[0]; a.async = 1; a.src = g; m.parentNode.insertBefore(a,m)
})(window,document,'script' , '// www.google-analytics.com/analytics.js','ga');

ga('create','UA-999999999-9','whatever.com');
ga('send','pageview');

< / script>

展示广告客户功能下,有一个选项说:


受众特征和兴趣报告可让年龄,性别和兴趣数据
可用,因此您可以更好地了解您的访问者是谁。要查看
这些数据,您需要对跟踪代码进行小改动。
详细了解如何进行这些跟踪代码更改。

/support.google.com/analytics/answer/2444872?hl=en&utm_id=ad\">https://support.google.com/analytics/answer/2444872?hl=en&utm_id=ad



基本上可以取代:

  ga.src =( 'https:'== document.location.protocol?'https:// ssl':'http:// www')
+'.google-analytics.com / ga.js';

与:

  ga.src =('https:'== document.location.protocol?'https://':'http://')
+'stats.g.doubleclick.net/ dc.js';

但这似乎是针对不同版本的Google Analytics(经典分析跟踪代码),而我正在使用新的Universal Analytics)...



我是否应该更换:

 })(窗口,文件, '脚本', '// www.google-analytics.com/analytics.js','ga'); 

有什么? (例如)

 })(window,document,'script','// stats.g.doubleclick.net/analytics的.js', 'DC'); 

另外,是否真的需要启用广告客户功能才能跟踪访客年龄和性别?我目前无意使用AdSense。

解决方案

据我所知,功能在第3阶段之前不适用于Universal Analytics。

这个连结有更多关于通用模式的资讯:
https://developers.google.com/analytics/devguides/collection/upgrade/



请参阅下面的文章欲了解更多关于在经典模式下做的信息。
http://online-behavior.com/analytics/demographics






升级页面包含以下内容,位于重要注意事项(强调 hjpotter92 ):


不支持与dc.js JavaScript库相关的数据集成,但即将推出。



dc.js Universal Analytics不支持JavaScript库,
但将在即将到来的一年。如果您依靠 dc.js 相关功能,
(例如再营销,Google展示广告网络展示报告,
DoubleClick Campaign Manager集成或Google Analytics b $ b受众特征和兴趣报告,请勿升级到Universal
Analytics。等到您在
Universal Analytics中看到关于 dc.js 的通知后,再升级。



I want to enable demographics and interests reports with the Universal Analytics tracking code.

The generated tracking code for my site looks like this:

<script>
  (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
  (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
  m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
  })(window,document,'script','//www.google-analytics.com/analytics.js','ga');

  ga('create', 'UA-999999999-9', 'whatever.com');
  ga('send', 'pageview');

</script>

Under Display Advertiser Features there is a option saying:

Demographics and Interest Reports make Age, Gender, and Interest data available so you can better understand who your visitors are. To see this data, you need to make a small change to your tracking code. Learn more about how to make these tracking code changes.

It links to: https://support.google.com/analytics/answer/2444872?hl=en&utm_id=ad

Which basically tells me to replace:

ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') 
   + '.google-analytics.com/ga.js';

With:

ga.src = ('https:' == document.location.protocol ? 'https://' : 'http://')
  + 'stats.g.doubleclick.net/dc.js';

But this seems to target a different version of Analytics (Classic Analytics tracking code, and I am using the new Universal Analytics)...

Should I just replace:

})(window,document,'script','//www.google-analytics.com/analytics.js','ga');

With something? (E.g.)

})(window,document,'script','//stats.g.doubleclick.net/analytics.js','dc');

Also, do I really need to enable Advertiser Features in order to track visitors age and gender? I have currently no intention in using AdSense.

解决方案

As I know , the feature is not available for Universal Analytics until phase 3.

This link has more information about Universal Mode: https://developers.google.com/analytics/devguides/collection/upgrade/

Refer the article below for more info about do it in Classic Mode. http://online-behavior.com/analytics/demographics


The upgrade page has the following content under the section "Important Considerations" (emphasis hjpotter92):

Data integrations related to the dc.js JavaScript library aren’t supported, but are coming soon.

The dc.js JavaScript library isn't supported in Universal Analytics, but will be in the coming year. If you rely on dc.js related features, such as Remarketing, Google Display Network Impression Reporting, DoubleClick Campaign Manager Integration, or Google Analytics Demographics and Interests Reports, do not upgrade to Universal Analytics yet. Wait until you see an announcement about dc.js in Universal Analytics, and upgrade then.

这篇关于在Universal Analytics中启用受众特征和兴趣报告的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆