I have a small app that have some custom data in the form of:
date value value_type
where value_type is old or new. Is there away to send the data to google analytics and have it analyzed there?
I have seen custom events here but I couldn't quite figure out how they would work my scenario.
Related
Does the time get stored with the date OOTB with the Google Analytics 4 (GA4) on eCommerce events?
On my company’s implementation when I look at the data stored to e-commerce events, like the purchase dimension, everything is showing as occurring at 12am. Do you know why this is? Is it a config issue or the way I am connecting?
I’ve seen posts where people create JavaScript variables to track time in GA4 and save to a dimension but this makes no sense given the high cardinality of time. I would have thought it would be more efficient to store as a datetime data type and track as part of the GA4 application.
Does anyone here see the time an event occurred on GA4 eCommerce events?
Currently, in my project "dev--sci" I do not see a third column with View Settings to get my view ID from (need this to call Google Analytics API).
I followed the directions from this stack overflow answer, which called for creating a new universal property. However, this appears to take me out of "dev--sci" altogether and create a new project called "views (UA-XXXXXX)", which does have the View Settings. But I need the view ID for my original "dev--sci" project, not this blank new one.
How do I get the view ID for my original project "dev--sci" and why doesn't it have the third view column? I believe it's b/c GA V4 doesn't have views, but then for some reason their API still requires it?
As you read in that post, GA4 does not have views, so if you are looking for a view ID to be able to use the APIs that require it in GA4, it means that you are using the wrong APIs, i.e. those that work with Universal Analytics (UA-XXXXX- XX).
GA4 uses a completely different data model from that of Google Analytics, for this reason the APIs to be used are different.
Here you can find some information about Google Analytics Data API V1 that provides programmatic methods to access report data in Google Analytics 4 (GA4) properties:
https://developers.google.com/analytics/devguides/reporting/data/v1
However, as you can see, this is an early preview version of the API and is subject to change:
Google Analytics (particularly version 4, "GA4") has various predefined events, each with its own parameters. E.g. the purchase event has an items parameter, which contains data such as item_id and item_name for each purchased item. JS code on a website can send these events and pass the extra data, and I can actually see the data in the "Analysis hub" in the Google Analytics interface.
Is there a way to also fetch this extra data using the Google Analytics Data API? There is a way to retrieve some predefined dimensions and also "custom dimensions" (via customEvent:parameter_name), but e.g. purchase item data doesn't seem to be a part of that.
Do I have to define custom dimensions (e.g. a purchasedProductId) and send them in addition to the items parameter, if I want to access this data via API?
Jan,
Ecommerce reporting is not yet supported in the Google Analytics Data API. I will update this question once I have more information about the timeline of this feature implementation.
Thanks,
Ilya
The Google Analytics Team
I am new to Google Analytics. I have a conversion set up, and I'd like to capture demographics for individuals who convert at e individual level. When a user converts, I'd like to pass the statistics from Google Analytics into my own database, or keep a record of the ID assigned at conversion in Google Analytics and download the data. Is this possible? I want to do analysis on who is likely to convert versus not - age, shopping habits, etc - and link these details back to the type of specific conversion.
Thoughts?
We if want to add add track users at individual level, try creating a Custom diamension and passing the userID everytime you make a GA call.
Next to view the same :- in tables that you view your analytics data, there will be this option called 'Secondary diamention', from the list that appears.. Choose the custom diamension name that you had assigned. Now you will be able to see each row with the userID along slide.
Add user ID to your tracking script
The first step to your question is to add the user ID to your tracking. If you have some way to identify users on your website (ie: through email marketing tool, your CRM, etc), then you should set up user ID tracking. Here is the Google Dev article about that:
https://developers.google.com/analytics/devguides/collection/analyticsjs/cookies-user-id?hl=en
However, basically... you just have to add this to your tracking script (replacing the 'create' line you currently have, replacing "USER_ID" with the user ID your system gives them.
ga('create', 'UA-XXXXX-Y', { 'userId': USER_ID });
In addition, I usually include this UserID as a custom dimension, so that I can view it in Google Analytics and other reports. To do this, first set up a custom dimension for your ID, as a "User-level" dimension. Then just add this after your user ID is available (assuming this is your first custom dimension):
ga('set', 'dimension1', USER_ID);
Connect User ID to Demographics
Unfortunately, the demographics information that Google Analytics provides (under "Audience") is not compatible with custom dimensions (like userID). So, the API only allows you to pull the audience data in aggregate (ie: connected to City, number of users, pageviews of those types of people... etc). If this works for you, check out the GA Query Explorer (below) to try out different combinations of dimensions & metrics to drill down as deep as you can and maximize the information you gain from this demographic info.
Connect Google Analytics Data to Your Database
In order to connect GA data to your database in an automated fashion, you will need to set up some kind of scheduled process that runs a query off of the Google Analytics API. To explore what combinations of metrics and stuff are available, I'd suggest checking out the Google Analytics API Explorer and the Google Analytics API reference material. What I did was set up an SSIS package (using SSIS GoogleAnalyticsSource) as the data source, which made it fairly easy. Then just scheduled that to run daily, populating the data I want into my database.
Alternatively, you could download less complicated reports directly from Google Analytics and import them into your database with something like SQL Server Management Studio.
I have a registration form with default fields and one drop down with 5 values say 1 - 5 And this field is mandetory.
How could i track this values thorugh Custom Variables for successful registered users?
What would be the other options if we cont track this through CV's?
Custom variables are pretty much a thing of the past - Universal Analytics has custom dimensions which are conceptually different and are not very well suited to store form input. Plus there is the danger that the form contains info that can be used to identify a person, and it's against Googles Terms of Service to store that in Google Analytics.
One possible way to solve this would be to create a Spreadsheet on Google Drive and publish it as a webapp to store the form data along with an anonymized ID per user; the same user id would be set as a session based custom dimension in Google Analytics. Using the Google Analytics Spreadsheet add-on or a bit of bespoke Google Apps Script you could then pull the relevant metrics per id into the spreadsheet to create your reports.