Advanced Segments & E-Commerce

Tuesday, February 03, 2009 | 11:39 AM

Labels: ,

Imagine that you are the online marketing manager for a successful E-Commerce business. It is Friday afternoon and your CEO phones with a request. "I've seen our sales numbers, but I need more data. How many of our website visits and sales relate to men's products versus women's products?"

"Sure, I'll have it for you next week," you reply cheerily.
Your CEO almost sounds apologetic and explains that she needs the information tomorrow. "Of course," you reply, and hang up the phone wondering how you are going to pull this off.

After considering it, you realize that this may not be so hard after all. All you need to do is:
  1. Find out if there is a unique URL identifier that distinguishes men's and women's products
  2. Create two advanced segments based on the unique URL identifier: one for men's products, and one for women's products
  3. Apply these segments to the reports to compare metrics/trends for each product category
That's it - it's as easy as 1, 2, 3!

Step 1 - Review your website URL structure


For this website, the men's product section and pages have an identifier called "bysex=1" in the URL, whereas the women's product section and pages have "bysex=2". You might want to double-check with your webmaster and/or web developer to identify all identifiers for each category. For this site, there are two additional identifiers, "CatID=1" and "men" as well as "CatID=2" and "women." Jot all this information down and then get ready to create your advanced segments.

Step 2 - Create Advanced Segments in Google Analytics

Within your Google Analytics report, click on one of the "Advanced Segment" links (see images below) and then click on the "Create a new advanced segment" link. If you need more details on the concept of segments and advanced segments, check out this video or read this post on how to create advanced segments.



In the above image, you'll see what information you need to create the advanced segments. You select the "Page" dimension, set the condition to "Contains" and set the value equal to the identifier you jotted down earlier. Since we had two more identifiers, you would want to include other pages that have these two identifiers, namely "CatID=1" and "men." You save this segment, give it a meaningful name such as MenCategory, and then create another segment for the women products category and use its identifiers, "bysex=2," "CatID=2" and "women," and follow the steps we used for the men's advanced segment.

Step 3 - Apply GA Advanced Segments and Analyze

After creating and saving your advanced segment, apply this new segment to your reports (by clicking on the "apply to report" link), and let the fun begin!


A few tips: apply the segments together so that you can compare (use the "Advanced Segments" dropdown in the top-right corner of your reports to apply segments). Here, we're comparing the All Visits segment (which is always selected by default) with the WomenCategory and MenCategory segments. While the results do not indicate if the visitor is a male or a female, the advanced segmentation provides insight into which clothing line category is currently driving more visits. You're now able to start some deep-dive analysis and provide some actionable insights to the CEO.

A few quick notes about your segments:
  • The visits will never add up because the "all visits" segment includes visits to other categories and bounces off of the homepage.
  • Similarly, the pageviews will not add up, because you could visit both the men's and women's categories in one visit or even visit neither category.
  • You can see that the specific categories seem to be of more interest to the visitor. A much higher pages per visit, much lower bounce rate, and a higher average time on site. You could act on this by directing traffic (paid, banner, e-mail) to a specific category instead of dumping them on the home page.
  • Such a large amount of traffic makes the site an excellent candidate for Google Website Optimizer!
Congratulations! You've proven yourself yet again to your CEO (and you'll still keep your Saturday for yourself :))

Additional Resources

Do you run an e-commerce site? Post a comment and tell us how you use Advanced Segments.

18 comments:

Denise said...

I have used advanced segmentation quite a bit but never in this capacity. I would love to see more tutorials like this. This will help me and my clients quite a bit.

EpikCharles said...

Great post.

I think it's important to point out that advanced segments apply to visits. With the "Page" dimension, you're really saying, "Show all visit data for any visitors that saw this page during their visit". This means the visitor may have seen the men's section of the site, but gone on to purchase only women's clothing. In this case all revenue data would be included in the "MensCategory" segment.

When using the Page dimension, your really trying to determine if a visitors experience with a certain page/section/feature of the site effects their propensity to perform a given action (buy a product, view 20 pages, etc.).

Rehan Asif said...

Thank you everyone for your comments.

EpikCharles is right, advanced segments apply to visits.
Still, I think this is a good step forward and hopefully it will inspire others to come up with even better techniques.

SEO Girl said...

I really appreciate this sample. It's very useful for me because it gave me a general case of using Advanced Segments in Analytics. Please keep going on posting articles like this! :)

Lavan said...

Thanks for the great post! This should really help me digest the content on the site I am currently working on. I was wondering, does this filter method work on subdirectories in a domain? For example:

http://www.domain.com/product_type1/

Contains a listing of all brands that fit that product type. Once they click on a specific product then the URL is

http://www.domain.com/product_type1/brand/product.html

Basically I would like to be able to do the same sort of dissection but by the directories (in this case /product_type1/ or /brand/. Is that possible?

Thanks in advance.

Lavan

E-Nor Feras said...

Hi Lavan,

I am glad you found the post useful. If I understand your comment correctly, you can accomplish what you want by applying the concept of "content grouping", check out the following link for more details: http://www.e-nor.com/blog/index.php/web-analytics/content-grouping-in-google-analytics/

Thanks,
Feras
www.e-nor.com (GAAC)

Aji said...

I recently came accross your blog and have been reading along. I thought I would leave my first comment. I dont know what to say except that I have enjoyed reading. Nice blog. I will keep visiting this blog very often.


Alanna

http://www.craigslisthelper.info

s said...

Does anyone know if you can set-up product categories in GA? Whenever I do a search it sends me to advanced segments. I don't want to know how many people visited these pages I want to find out what items in a certain category sold and whatnot.

Rehan Asif said...

Hi s,

I think what you are probably looking for is provided by ecommerce tracking in Google Analytics.

It takes some configuration and integration with your shopping cart, but every transaction sends some detail to Google Analytics, including the category of the purchase, and then you can see a wealth of new reports.

Tracking ecommerce transactions in Google Analytics

Justin Fleming said...

It seems you are limited to 20 OR statements in an advanced segment?

I'm trying to track any visits from a specific set of referring websites (affiliates) and now can't since I have more than 20 to track.

Any ideas?

Could have just have put each website in it's own advanced segment and then just ticked all the appropriate advanced segment boxes when viewing a report BUT it also doesn't let you tick more than 3 boxes.

:/

Rehan Asif said...

Hi Justin,

It may be possible to group some of those referring websites with a regular expression.

Could you give an example, modified for privacy, of the referring websites you are trying to group?

Justin Fleming said...

I know what you mean but they are basically completely random urls that could be anything (as far as you are concerned).

Literally the only thing the urls have in common is that I already know what they are. They are not using an affiliate url code or anything,

They could be for example,

microsoft.com
google.co.uk
news.bbc.co.uk
myspace.net

So until I hit the 20 'OR' limit, I just had these in a single Advanced Segment called All Affiliates.

Rehan Asif said...

Hopefully Googlers are listening to your feedback - longer text fields are always nice for power users.

Here is something that might work for you but it involves creating filters and applying them to a new profile, and then doing your grouping with advanced segments:

1) Create a new profile.
2) Create an advanced filter with "Field A -> Extract A" set to Campaign Source and the value set to microsoft\.com, and "Output To -> Constructor" set to User Defined and the value set to my_affiliates.
3) Repeat step 2 for all the traffic sources you want to track.
4) Apply these new filters to just the new profile.
5) Create an advanced segment in the new profile with User Defined matching my_affiliates.

I have never done the above so you would have to test it (thankfully it is limited to a single profile).

Let us know how it works out.

Rehan Asif said...

To add to my previous comment, you could also do something similar with javascript.

At a high level, you look at the referrer, if it is one of your referring sites, you execute setvar with a value like my_affiliates.

Then you create an advanced segment inside your existing profile and look for User Defined equal to my_affiliates.

The first way is filter based and the changes are limited to one profile, the second way is script based and sends the User Defined to all your profiles.

Take your pick and try one or both out.

Sebastian Tonkin said...

Yes Rehan, we are listening!

-Sebastian

Barbara said...

I've created an advanced segment for all those pages that contains /videos.
The thing is that if I apply this video segment in the general dashboard, it has like 70.000 pageviews. But if I go to content's report and filter by all those pages that contain /videos (with no advanced segment applied), I get just 17.000 Pageviews.
I don't understand why there is such a big difference... anyone could help me to understand this? :)

Rehan Asif said...

What you are seeing is a side effect of how advanced segments work.

In the video segment you created, you are looking at all visits that included a pageview of /videos.
But it also includes all other pageviews from those visits.
Your pageview list is not exclusively /videos.

When you look at just the Top Content report and filter by /videos, you see all the pageviews for /videos...and nothing else.

BlazingStreams said...

Thanks for the clarification Rehan. To include all pageviews for a visit seems rather counter productive since in this particular instance my goal would be too see how many people are view specific page(s) in an automated fashion,