I am working on Google Analytics to fetch following data from query-explorer
I want following data for current Month:
userID = saved in dimension ga:customVarValue2
Timestamp = I took dimension ga:dateHourMinute
url = I took ga:hostname and ga:pagePath
I want only two metrics related to DFP clicks and impressions
Since there are no any DFP dimensions,so I entered only impressions and clicks here and it shows me query error (Please see the screenshot)
Can Anybody please explain me how to get data related to DFP clicks and impressions here.
Thanks in Advance
DFP Reporting needs to be set up before you can query on it. There are certain requirements you have to meet in order to be able to make the reports.
https://support.google.com/analytics/answer/6183304
Related
Background
I am currently using Google Tag Manager to populate the Sales amount into a Custom Metric in Google Analytics. This is the code I use to push Sales amount to Google Analytics.
ga('set', 'metric2', {{salesvalue}});
Other information
My custom metric set up in Google Analytics: https://i.imgur.com/kX3aUto.png
I know that the metric is firing with the correct values since it is showing up in GA Debugger: https://i.imgur.com/lGIxCw1.png
Error
Despite the above, I do not see any information in Google Analytics: https://i.imgur.com/WtxChgY.png
Questions
Is there anything wrong with my setup? I have waited over 3 days but still no data.
By using ga('set') does it mean that if a user makes 2 separate purchases in the same session, only the latest sales figure will be reflected instead of the total of the 2 purchases?
Thank you
In your GA Debugger console, the metric2 parameter should be appearing within the pageview send data (along with all the other data being sent to GA at that time). If it is not there, you could be running into a race condition or some other technical issue. If it is there, then you'll know that it is definitely being sent to Google Analytics and something else is wrong. It should not take long to appear, and if you see any rows of data (as you did with your screenshot) the metric data would be there at that time.
Regarding your 2nd question, custom dimensions have scopes that are configured when you create them, but custom metrics simply add up. If I had a custom metric of "clicks on a button" and user clicked it 3 times in their session, the custom metric would be 3. Likewise, if your custom metric is listening for sales value, it will add up to the total value in that session.
Hope that helps at least get you some more clues as to what is wrong.
I want to get the page view data from Google Analytics using R. I am using googleAnalyticsR package for getting these data using R.
Currently, I can get the landingPagePath, secondPagePath, previousPagePath, exitPagePath information. But I want to get the whole viewed pages in that session which transaction occurred. For instance, let's say a visitor came to the my website and logged in. After that s/he visited in pages titled as below in a given order
Page1 > Page2 > Page1 > Category > Product12 > Product13 > Basket > Checkout
I want to get this view flow as it is. I cannot do it using google analytics api's metrics & dimensions for page tracking.
How can I get the full 'view flow' data? Can I create such a report using only google analytics reports? Or should I try something else?
Thanks for any advice,
Best.
Google Analytics is basically a database where every hit (pageview, event, etc) is a single row. Try fetching these dimensions:
Page
Date, Hour, Minute, Second
metrics:
Pageviews
sort by Date, Hour, Minute, Second
Once you got all the data, create logic in R finding most common pathes.
Normally, BigQuery is used for such tasks (if you have Analytics 360 - GMP, payed version off GA). In BigQuery you have hit number
In GA dashboard, there is only report of number of active users in a day or week or year. If I need a report to collect which user id who visits my website, I have to click the range of the date day by day and export so many excels in order to combine them into one.
Is it possible to get a list of all user ids day by day.
The user id field that you have submitted with your google analytics hit data is used for internal processing. It is not something that you can actually see in either the google analytics website or the google analytics api. Its used similar to the session id.
If you want to see it i recommend you try adding it as a custom dimension.
I need to fetch ecommerce data from google analytic for custom reporting using a php application. I need to fetch data like last 5 sales, total sales by date, by month etc. But, I am not getting any clue how to get data from analytic. Please give me a clue... Thanks in advance
I am interested in seeing visits on my site broken down by hour - is there any way to generate a report of this in Google Analytics? It appears that all metrics are only broken down by day. Maybe I can get this information through the GA API?
Since Google Analytics was revised the currently accepted answer is no longer available. The current version of Google Analytics will let you view visitors per hour:
Go to the Reporting Tab
Select "Audience"
Select "Overview"
Select "Hourly"
If you're trying to determine total traffic by hour of the day for a given date range then you can use this custom report:
https://www.google.com/analytics/web/permalink?type=custom_report&uid=pToP7693ReSxfSIpbqHmWg
Only a few reports have hour-by-hour data; as far as I know, they're all in the 'Visitors' section.
For example, to see Visits by hour over a period of time, click Visits, Visitor Trending, then Visitors. Then, in the top right of the report, select Graph by: (icon of a clock)
All of the reports under Visitor Trending have hour-by-hour data, except Absolute Unique Visitors.
As far as the API goes, you can check what query combinations are valid here (since there are restrictions): http://code.google.com/apis/analytics/docs/gdata/gdataReferenceDimensionsMetrics.html
According to that, all metrics can be viewed by an hourly dimension except Campaign metrics and Visitor (not to be confused with Visit) metrics.
You can test the query you want to run with the Google Analytics Data Feed Query Explorer
If using a (downloadable, emailable) custom report is an option, you can use the custom report described on http://salman-w.blogspot.com/2012/07/analytics-day-of-week-hour-of-day-report.html
The article tells you to do the following:
Create a custom report with flat table (I am sure it will work with explorer style reports too)
Add the dimension hour (not hour of day)
Add the metric visits, pageviews, etc
Preview