tom*_*mmi 1 google-analytics google-analytics-api ios
我正在发送用户时间数据,sendTimingWithCategory:withTimeInterval:withName:withLabel但我似乎无法在Google Analytics报告工具上找到这些数据.
在我的应用程序中,我尝试捕获不同类型的用户计时,这里有一些代码片段:
// duration1 & duration2 are instances of NSTimeInterval
id<GAITracker> tracker = [[GAI sharedInstance] defaultTracker];
[tracker sendTimingWithCategory:@"DurationOnApp" withValue:duration1 withName:nil withLabel:nil];
[tracker sendTimingWithCategory:@"DurationOnSectionA" withValue:duration2 withName:nil withLabel:nil];
Run Code Online (Sandbox Code Playgroud)
它让我印象深刻:是因为我应该给出一个价值,name而不是把它当作"零".
这工作:
[tracker sendTimingWithCategory:@"DurationOnApp" withValue:duration1 withName:@"DurationOnApp" withLabel:nil];.
显然,类别和名称都是必要的.用户计时现在出现在Engagement - > App Speed中
| 归档时间: |
|
| 查看次数: |
2710 次 |
| 最近记录: |