我想将 GoogleAnalytics 调用添加到我的 Android 应用程序。我在 GoogleAnalytics 中创建了帐户,下载了库,实例化了 GoogleAnalyticsTracker 类,编写了如下调用:
tracker.trackPageView(myData);
整个应用程序。我的问题:作为 Google 分析用户,我如何查看所有分析数据?我想检查一切是否正常。
我想将 GoogleAnalytics 调用添加到我的 Android 应用程序。我在 GoogleAnalytics 中创建了帐户,下载了库,实例化了 GoogleAnalyticsTracker 类,编写了如下调用:
tracker.trackPageView(myData);
整个应用程序。我的问题:作为 Google 分析用户,我如何查看所有分析数据?我想检查一切是否正常。
Several options available to you:
-Google Analytics offers real-time tracking. Easiest thing to do would be to have Analytics open in a window on your machine, and watch for hits as you use your application.
-Also, by calling
tracker.setDebug(true);
You can enter debug mode, which means all requests to GA are sent to the Android log, which you can view using DDMS (either stand-alone or as part of the eclipse plugin). This is probably the option you want. In this case you probably also want to call
tracker.setDryRun(true);
which will prevent the data from actually being sent to GA servers, so you can experiment all you want without messing up your production stats. Of course, be sure to remove this line before you ship :)
由于我使用了 trackPageView 方法,所以我发送的所有数据都存储在 Google Analytics 中的 Content -> Site content -> Pages 中。这是访问页面的列表。