{"id":445,"date":"2010-11-06T16:13:11","date_gmt":"2010-11-06T13:13:11","guid":{"rendered":"http:\/\/blog.denivip.ru\/?p=445"},"modified":"2013-08-05T14:12:45","modified_gmt":"2013-08-05T10:12:45","slug":"visitors-segmentation-in-google-analytics","status":"publish","type":"post","link":"http:\/\/blog.denivip.ru\/index.php\/2010\/11\/visitors-segmentation-in-google-analytics\/?lang=en","title":{"rendered":"Visitors segmentation in Google Analytics"},"content":{"rendered":"<p><center><a href=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/google-analytics-hacks.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/google-analytics-hacks.png\" alt=\"\" title=\"google-analytics\" width=\"467\" height=\"348\" \/><\/a><\/center><br \/>\nIn this post, we will continue to discuss not so widely known but still pretty useful features of Google Analytics, and apply them to real cases. We believe that visitor segmentation might be effective for almost all Web sites. Normally, every business has more than one target group of customers. So it is very interesting to group your prospects (visitors) to get an idea how to convert them. The more groups you have, the higher is the probability to develop a successful strategy to add prospects to your customer base. <!--more--><\/p>\n<p>In our case, we\u2019ll make an simple, but a real life case study. We have a corporate website and a blog. The company&#8217;s employees constantly develop the site &#8212; making improvements, adding features and spending too much time on it. So the objective is to sort out site visits and usage of such visitors.<\/p>\n<p>At the first sight, this could be done with Google Analytics filters. But in our case, they are all but applicable: the company&#8217;s employees have dynamic IP addresses, some of them access the site from their homes and via the mobile networks. In such cases, you can apply Google Analytics user segmentation tools. To solve the problem, let\u2019s create a new user segment consisting of the employees of the company, and then sort out their data in the Google Analytics administration interface.<\/p>\n<p>First, select a page available to the employees only. For this purpose, you can create an internal zone requiring sign-in or use your administration interface. Then, before the page tracking code, add a JavaScript method call<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;width:540px;\"><table cellspacing=\"0\" cellpadding=\"0\"><tbody><tr><td class=\"line-numbers\"><div>1<br \/><\/div><\/td><td><div class=\"text codecolorer\">_setCustomVar (index, name, value, opt_scope)<\/div><\/td><\/tr><\/tbody><\/table><\/div>\n<p>to set a user variable.<\/p>\n<p>This function accepts 4 parameters:<\/p>\n<ul>\n<li><strong>index<\/strong> \u2014 a slot for the variable, ranging from 1 to 5. So you have up to 5 variables for each event \/ visit. If you need more, then probably you should buy commercial off-the-shelf systems like Omniture.<\/li>\n<li><strong>name<\/strong> \u2014 the name of the variable shown in the Google Analytics reports.<\/li>\n<li><strong>value<\/strong> \u2014 the value of the variable; typically, several possible values are used for a variable.<\/li>\n<li><strong>opt_scope<\/strong> \u2014 the scope of the variable, numeric: 1 (user level), 2 (session level) and 3 (page view level). Default value is 3 (page view).<\/li>\n<\/ul>\n<p>Finally, you should get something like this:<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;width:540px;\"><table cellspacing=\"0\" cellpadding=\"0\"><tbody><tr><td class=\"line-numbers\"><div>1<br \/>2<br \/>3<br \/><\/div><\/td><td><div class=\"text codecolorer\">var pageTracker = _gat._getTracker(&quot;UA-XXXXXXXX-X&quot;);<br \/>\n&lt;strong&gt;pageTracker._setCustomVar(1,&quot;Visitor_Type&quot;,&quot;Employee&quot;,1 );&lt;\/strong&gt;<br \/>\npageTracker._trackPageview();<\/div><\/td><\/tr><\/tbody><\/table><\/div>\n<p>It is worth noting that the<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;width:540px;\"><table cellspacing=\"0\" cellpadding=\"0\"><tbody><tr><td class=\"line-numbers\"><div>1<br \/><\/div><\/td><td><div class=\"text codecolorer\">_setCustomVar<\/div><\/td><\/tr><\/tbody><\/table><\/div>\n<p>method was introduced quite recently to replace the old<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;width:540px;\"><table cellspacing=\"0\" cellpadding=\"0\"><tbody><tr><td class=\"line-numbers\"><div>1<br \/><\/div><\/td><td><div class=\"text codecolorer\">_setVar<\/div><\/td><\/tr><\/tbody><\/table><\/div>\n<p>method. The values set with<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;width:540px;\"><table cellspacing=\"0\" cellpadding=\"0\"><tbody><tr><td class=\"line-numbers\"><div>1<br \/><\/div><\/td><td><div class=\"text codecolorer\">_setCustomVar<\/div><\/td><\/tr><\/tbody><\/table><\/div>\n<p>appeared in statistics more than a day later, while the<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;width:540px;\"><table cellspacing=\"0\" cellpadding=\"0\"><tbody><tr><td class=\"line-numbers\"><div>1<br \/><\/div><\/td><td><div class=\"text codecolorer\">_setVar<\/div><\/td><\/tr><\/tbody><\/table><\/div>\n<p>assignments emerged in several hours. In any case, you\u2019d better use the new method, as the old might be phased out anytime.<\/p>\n<p>Finally, we have to tune the Google Analytics admin interface. Let\u2019s go. First, make sure that the segmentation data is received by Google Analytics. Check the report &#171;Visitors&#187; -> &#171;Custom variables&#187;. It should contain the custom variables as follows:<br \/>\n<a href=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_CustomVars.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_CustomVars.png\" alt=\"\" title=\"GA_CustomVars\" width=\"512\" height=\"164\" class=\"alignnone size-full wp-image-139\" srcset=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_CustomVars.png 512w, http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_CustomVars-300x96.png 300w\" sizes=\"(max-width: 512px) 100vw, 512px\" \/><\/a><br \/>\n\u0415\u0441\u043b\u0438 \u0412\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438 \u043c\u0435\u0442\u043e\u0434<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;width:540px;\"><table cellspacing=\"0\" cellpadding=\"0\"><tbody><tr><td class=\"line-numbers\"><div>1<br \/><\/div><\/td><td><div class=\"text codecolorer\">_setVar<\/div><\/td><\/tr><\/tbody><\/table><\/div>\n<p>\u0442\u043e \u043d\u0443\u0436\u043d\u043e \u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0434\u0440\u0443\u0433\u043e\u0439 \u043e\u0442\u0447\u0435\u0442: &#171;\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0438&#187; -> &#171;\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c&#187; \u0438 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043e\u043d \u043f\u0440\u0438\u0431\u043b\u0438\u0437\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0442\u0430\u043a:<br \/>\n<a href=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_UserDefined1.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_UserDefined1.png\" alt=\"\" title=\"GA_UserDefined\" width=\"512\" height=\"325\" class=\"alignnone size-full wp-image-141\" srcset=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_UserDefined1.png 512w, http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_UserDefined1-300x190.png 300w\" sizes=\"(max-width: 512px) 100vw, 512px\" \/><\/a><br \/>\nNow you can segment most reports and analyze data in the context of the company employees and outside visitors. To obtain the segmented data, in the upper right corner select &#171;Advanced Segments&#187; and then click &#171;Create a new advanced segment&#187;. In the segment designer indicate that the Custom variable (value 1 &#8212; slot) should not contain &#171;Employee&#187;, to sort out the company&#8217;s employees. After this, test the segment, to make sure there are no errors in the settings.<\/p>\n<p><a href=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_CustomSegment.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_CustomSegment.png\" alt=\"\" title=\"GA_CustomSegment\" width=\"512\" height=\"168\" class=\"alignnone size-full wp-image-143\" srcset=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_CustomSegment.png 512w, http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_CustomSegment-300x98.png 300w\" sizes=\"(max-width: 512px) 100vw, 512px\" \/><\/a><\/p>\n<p>After this, choose this segment in the report and enjoy the segmentation. You will see something like this:<br \/>\n<a href=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_ExternalVisits.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_ExternalVisits.png\" alt=\"\" title=\"GA_ExternalVisits\" width=\"512\" height=\"80\" class=\"alignnone size-full wp-image-142\" srcset=\"http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_ExternalVisits.png 512w, http:\/\/blog.denivip.ru\/wp-content\/uploads\/2010\/05\/GA_ExternalVisits-300x46.png 300w\" sizes=\"(max-width: 512px) 100vw, 512px\" \/><\/a><br \/>\nTo avoid configuring segmentation every time, set the filter for employee visits. We recommend you to create a separate profile for the filter, as after applying the filter you will not be able to view the source data.<\/p>\n<p>Now you can generate ideas on how to use this tool for more advanced segmentation in order to know more of your visitors. You can use this approach to track behavior of different groups of users: unknown visitors, current customers, people communicating in your blog, users subscribed to your mail list, etc.<\/p>\n<p>We would be happy if you share your opinion on the article and your unique experience with the features discussed.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this post, we will continue to discuss not so widely known but still pretty useful features of Google Analytics, and apply them to real cases. We believe that visitor segmentation might be effective for almost all Web sites. Normally, every business has more than one target group of customers. So it is very interesting [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[24,32,31,8],"_links":{"self":[{"href":"http:\/\/blog.denivip.ru\/index.php\/wp-json\/wp\/v2\/posts\/445"}],"collection":[{"href":"http:\/\/blog.denivip.ru\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.denivip.ru\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.denivip.ru\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.denivip.ru\/index.php\/wp-json\/wp\/v2\/comments?post=445"}],"version-history":[{"count":6,"href":"http:\/\/blog.denivip.ru\/index.php\/wp-json\/wp\/v2\/posts\/445\/revisions"}],"predecessor-version":[{"id":4881,"href":"http:\/\/blog.denivip.ru\/index.php\/wp-json\/wp\/v2\/posts\/445\/revisions\/4881"}],"wp:attachment":[{"href":"http:\/\/blog.denivip.ru\/index.php\/wp-json\/wp\/v2\/media?parent=445"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.denivip.ru\/index.php\/wp-json\/wp\/v2\/categories?post=445"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.denivip.ru\/index.php\/wp-json\/wp\/v2\/tags?post=445"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}