How to analyze multiple query parameters in Google Analytics - google-analytics

I'm setting up Google Analytics for a website where a user can find an event to attend (concerts, plays, etc.). The results can be filtered by 5 different parameters.
So, unfiltered results would look like: example.com/event-finder/
And filtered results showing concerts in January or February would look like: example.com/event-finder?type=concert&month=jan,feb
I'm struggling to figure out the best way to use the query parameters in Google Analytics to analyze filtering behavior.
Example questions I'd want to be able to pull answers for:
What percentage of results were filtered by type?
What percentage of results were also sorted by month?
What is the most common type filtered by?
I have full access to both Google Analytics and Tag Manager but I suspect I shouldn't do this with events or custom dimensions and that there's got to be a way to use the query parameters to do this in a clean way.
I've tried to use a new view and site search to group the types of filters. Seems like it could work, but seems hacky and limited.
I've considered pushing those values into custom dimensions, but that too seems like overkill.
I've considered pulling content reports into Google Sheets and sorting through things there, but I'm 1) not entirely sure how I'd do that and 2) suspect there may be an easier approach.
Let me know if you have any questions or need more clarification. Thanks!

Have you tried to use "category parameters" when configuring site search (admin -> view settings)? You could set the "type" as a category parameter. You can also enter multiple parameters in there.
Check this screenshot of site search configuration

Related

Use look-up table in Tag Manager to determine which Analytics Property to post data to, based on URL

I have two websites on the same domain: example.com/fr and example.com/us. Each website has its own Google Analytics Property. I'd like to record page view data in each website's respective Analytics property.
Since there may be many more websites and Analytics Properties in future I thought the best way to manage this would be to create a custom variable of type RegEx Table to map Page URLs to Analytics Property Ids, like this:
*example\.com/us* maps to: UA-123456789-0
*example\.com/fr* maps to: UA-123456789-1
etc
…then use that variable as the value of the 'Google Analytics Settings' field in a new Universal Analytics Tag. I feel like I've set this up properly but it just will not log any data in Analytics whatsoever. I've tried it with even the loosest RegEx patterns e.g *example\.com* and even * and still nothing gets into Analytics.
I've tried a similar thing using a Lookup Table (as opposed to a RegEx Table) and that works as expected, but I believe a look-up table is limited to matching only an exact URL, so if I map http://example.com/us/ to UA-123456789-0 (my US site's Analytics Property Id) it works great when I visit that page exactly, but when I visit http://example.com/us/test/ it doesn't log anything as the URL isn't matched exactly in the lookup. So I know the principle of what I'm doing works with a Lookup Table, but it seems the same approach doesn't work with a RegEx Table.
I wanted to ask:
It is possible to use a Regex table for outputting an Analytics Property Id?
If so, any pointers as to what I might have done wrong?
If not, are there any other neat options? (Otherwise I'm potentially going to have to set up a lot more variables/events/tags if I need to log the same things on each site to different Analytics Properties - it'd involve adding the same conditions onto pretty much every tag.
Many thanks.
As prompted by the comment from #EikePierstorff, it seems that it is possible to use a Regex Table as a lookup for determining the Analytics Property Id to use based on URL. The simple issue was incorrect RegEx expressions.

Google Analytics Absolute Change Sort in Custom Reports

I have a problem with my Custom Reports in Google Analytics. I'm trying to compare periods but it seems impossible to use Absolute Change sort within Custom Reports. Instead, the same option is available in classic reports. Is absolute change sort option available for custom report? Thank you in advance for your help.
Edit: Unfortunately I can't attach any photo, but I will try to explain better. As you surely know in Google Analytics I can compare data with a previous period. Analytics allows the user to sort the compared data through several Sort Types. There are three Sort Types available: Default, Absolute Change and Weighted. Each one of these takes into account different algorithms to sort data. You can switch to a different sort type just by using the drop-down menu placed beside "Secondary Dimension", above the results table. So, I checked out that In Custom Reports the "Absolute Change" option is never made available: when I try to switch from Default to Absolute type, the entry "Absolute Change" is disabled, so I can't select it. It seems to be a trivial feature of Analytics, and I'm not sure whether it is a limitation of custom reports, or maybe if I configured something wrong.

Google Analytics - Tracking Nonstandard Query Strings

I am trying to track query strings in Google Analytics, but I have a problem. I have too many variables to fit in the "normal set" provided by Google. They allow you to set utm_source, utm_medium, utm_term, utm_content and utm_campaign. I need another one, let's call it my_qs.
So my URL would look like:
http://example.com?utm_source=stack-exchange&utm_medium=web&utm_term=google-analytics&utm_content=nonstandard-query-strings&utm_campaign=answers&my_qs=gotmike
I can obviously find reports for all the standard query strings in Google Analytics, but I'm having a tough time figuring out how to run reports on these other variables that show up in the URLs.
I looked into Custom Variables, and they seem like something that is set by the Google Analytics code, not by the query string in the URL.
Maybe the answer is to write some javascript to grab my query string and store it as a Custom Variable in Google Analytics?
I read several articles about creating Custom Variables based on data stored on your website, but I'd really like to provide a simple URL link back to my website and get the data from the query string based on a user clicking that link.
Any ideas on how to accomplish this?
If you are using GTM, then you can grab the query parameter quite easily by creating your own variable to grab your qp. The variable would look something like this:
You could then provide "my_qs parameter" as a value for your Custom Dimension in your tags. Make sure you have already defined and configured this in your GA account first.

Mixable metrics and dimensions in google analytics

I'm doing some complex reports for google analytics and would like to ask you if the following is possible. The client wants to have just organic data for a bunch of metrics. Like pageviews, visitBounceRoutes, etc. The query I ended up with is the following:
https://www.googleapis.com/analytics/v3/data/ga?dimensions=ga:source,ga:medium,ga:keyword,ga:day,ga:month,ga:year&end-date=2013-11-20&fields=columnHeaders/name,rows,totalResults,totalsForAllResults&filters=ga:medium==organic&ids=ga:79067749&metrics=ga:pageviews,ga:pageviewsPerVisit,ga:visitors,ga:avgTimeOnSite,ga:newVisits,ga:visitBounceRate&start-date=2013-10-20
However the response is as follows:
'{"totalResults":0,"columnHeaders":[{"name":"ga:source"},{"name":"ga:medium"},{"name":"ga:keyword"},{"name":"ga:day"},{"name":"ga:month"},{"name":"ga:year"},{"name":"ga:pageviews"},{"name":"ga:pageviewsPerVisit"},{"name":"ga:visitors"},{"name":"ga:avgTimeOnSite"},{"name":"ga:newVisits"},{"name":"ga:visitBounceRate"}],"totalsForAllResults":{"ga:pageviews":"0","ga:pageviewsPerVisit":"0.0","ga:visitors":"0","ga:avgTimeOnSite":"0.0","ga:newVisits":"0","ga:visitBounceRate":"0.0"}}'
Can the dimensions ga:source,ga:medium,ga:keyword be mixed with the above metrics? It seems they can't since if I omit them the API returns an array of values 1 per each day within the specified range.
Where can I find more information about this and what categories are mixable? https://developers.google.com/analytics/devguides/reporting/core/dimsmets just shows all the available metrics but do not explains how they are combined and which one would be valid requests. I'm new at the analytics API and would be great any kind of help or guidance
Thanks a lot
Google Analytics Query Explorer is your friend for playing around with analytics dimensions/metrics/filters ;-)
Try http://ga-dev-tools.appspot.com/explorer/?dimensions=ga:source,ga:medium,ga:keyword,ga:day,ga:month,ga:year&metrics=ga:pageviews,ga:pageviewsPerVisit,ga:visitors,ga:avgTimeOnSite,ga:newVisits,ga:visitBounceRate&filters=ga:medium%253D%253Dorganic&start-date=2013-10-20&end-date=2013-11-20&max-results=100
Some thoughts:
Those dimensions & metrics should work -- maybe there was no organic data recorded during that time range?
Try removing the ga:medium==organic filter and see what your data looks like.
Does the profile you're using (ga:79067749) have any filters on it? If so, maybe try a different profile that has unfiltered data. (Analytics best practices -- make sure you have a profile with no filters applied that captures all data.)
As Mike said, there is no problem with the combination of metrics and dimensions you are using.
If you are entering the URL query directly in the browser problem might be the lack of URL encoding in your query string. For example, you need to convert == to %253D%253D
For example, instead of ga:medium==organic, you need ga:medium%253D%253Dorganic
If you build your query in the Google Analytics Query Explorer as Mike suggests, you can grab the direct link to your report by clicking the link symbol in the upper left:

Google Analytics Custom Variable/Value Report (How?)

I was able to setup Google Analytics to send custom variables that I can track.
I'd like to generate a report with UserId / Value and Display all of the pages
that user viewed. (Similar to reports I have seen with IP address on one column,
and viewed pages on the other)
Custom Var 1 : label:'userId' value:'17' scope:'1' (from Chrome Analytics tool)
Google Analytics reporting is pretty complex, so I'm hoping I can get some suggestions on how to create such a report.
i'm battling through google analytics aswell it can be really useful but to get exactly what you want can take some time. This isn't an answer as much as its a list of a few links that i have used along the way and hope they help
http://ga-dev-tools.appspot.com/explorer/
In here if you put ga:source ga:referralPath ga:customVarName(n)
This stack overflow answer may also help
Create google analytics profile by filtering using a custom variable
i'll have to look into this myself when i m using custom variables but it look like the advanced segment section may be the way to go.
And you ve probably already seen this but its quite a nice article on custom variables
https://developers.google.com/analytics/devguides/collection/gajs/gaTrackingCustomVariables
Let us know hwo you get on...
I think you're going to want to create an advanced segment including your custom variable. This should narrow the data to only that which includes the variable. You can then look at whatever reports you want within that segment.
Using regular expressions should let you better tune the scope of the segment.
You can do this easily in the Megalytic reporting tool. There are widgets that let you create reports which segment data by custom variable. For example, Traffic by Custom Variable, Conversions by Custom Variable. Disclaimer: I am a founder of Megalytic.

Resources