我通过Google Analytics python API执行MFC查询,如:
query = service.data().mcf().get(
ids = "ga:79961457",
start_date = day,
end_date = day,
metrics = metric,
dimensions = "mcf:conversionDate,mcf:campaignPath",
sort = None,
filters = "mcf:campaignPath=@RTG,mcf:conversionType==Transaction",
max_results = 1000000000
).execute()
这会产生一个包含与此类似的行的列表:
{u' primitiveValue':u' 20160701'},
【U' conversionPathValue':
[{u' nodeValue&#39 ;: u' {{soporte}}',u' interactionType':u' CLICK'},
{u' nodeValue':你' RTG', 你的互动类型':你' IMPRESSION'},
{u' nodeValue':你' CAMP', 你的互动类型':你'点击'}],
{u' primitiveValue':u' 1'},FBRTG
现在,我应用的过滤器是
mcf:campaignPath = @ RTG
它会过滤所有" nodeValue"。
问题是我只想获得包含
的行{u' nodeValue':你' RTG', u' interactionType':你点击'},
(例如)
所以,问题是:如何将过滤器应用于interactionType,而不仅仅是campaignPath?