I'm trying to use google analytics API to retrieve some data to build a chart that displays number of visitor per day for current month.
However I'm almost completely lost with metrics and dimensions idea.
if I use ga:visitors metrics - that would only give me a total number of visitors - right? How would I retrieve visitors per each day in a month?
any advice would be greatly appreciated.
Thanks!
Dimensions are attributes of your data. For example, the dimension City indicates the city, for example, "Paris" or "New York", from which a session originates. The dimension Page indicates the URL of a page that is viewed. Metrics are quantitative measurements.
The correct answer is Sessions / Bounce Rate. Sessions and Bounce Rate both fall under the Metrics category in Google Analytics. Therefore, Sessions / Bounce Rate is not an accurate answer when looking for a metric-dimension combination.
Sign in to Google Analytics. Click Admin, and navigate to the property to which you want to add custom dimensions. In the PROPERTY column, click Custom Definitions > Custom Dimensions. Click New Custom Dimension.
I highly recommend using the Data Feed Query Explorer to get your feet wet:
https://ga-dev-tools.appspot.com/query-explorer/
You'll have to login with your Google Account and click the button to grant the application access. But it has a simple UI that lets you build your request. A good starting example might be:
This will give you pageviews and visitors per day, for every day in your date range.
The general idea is that you are building a table of sorts. Metrics are what you are measuring, and Dimensions are what you are grouping the Metrics by.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With