<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Anna</title>
    <description>The latest articles on Forem by Anna (@analyticsinstitute).</description>
    <link>https://forem.com/analyticsinstitute</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F481533%2F297520d8-1e54-45b2-aaf4-3c03221bf6d4.jpg</url>
      <title>Forem: Anna</title>
      <link>https://forem.com/analyticsinstitute</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/analyticsinstitute"/>
    <language>en</language>
    <item>
      <title>What Is the Data Layer and Why Do You Need It?</title>
      <dc:creator>Anna</dc:creator>
      <pubDate>Fri, 30 Dec 2022 17:19:09 +0000</pubDate>
      <link>https://forem.com/analyticsinstitute/what-is-the-data-layer-and-why-do-you-need-it-2hp4</link>
      <guid>https://forem.com/analyticsinstitute/what-is-the-data-layer-and-why-do-you-need-it-2hp4</guid>
      <description>&lt;h3&gt;
  
  
  Understanding the layered architecture of websites and apps
&lt;/h3&gt;

&lt;p&gt;If you work in digital marketing, you may have heard the term 'data layer' being thrown around a lot by the technical personnel. But what exactly is a data layer and why is it so important? We can think of the data layer as a part of a multi-layered structure that makes up many websites and apps. When it comes to online properties you are using for lead generation and e-commerce, there are usually three layers:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. The Presentation Layer&lt;/strong&gt;&lt;br&gt;
This is the layer that the user sees and interacts directly with. It's where the user interface is and is developed using frontend technologies such as HTML and CSS.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. The Application Layer&lt;/strong&gt;&lt;br&gt;
This concerns the logic, data exchange, and functionalities of the site or app, especially with respect to third-party tools satisfying your business needs. This is the layer where analytics software (e.g. Mixpanel) or marketing vendors (e.g. Google Ads) are connected to your site.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. The Data Layer&lt;/strong&gt;&lt;br&gt;
The data layer is a JavaScript object that can be added to a website to provide a standardized way for data collection throughout a user's journey. A website utilizing such a feature should have all the data readily available in the website's code so that when a user proceeds with a certain action for which data is relevant, that piece of data will be pushed to the data layer object. For example, if you have an e-commerce store, the data layer may contain the prices and IDs for products in the shop. If a user selects a certain product, the price and ID of the product selected would be exposed in the data layer.&lt;/p&gt;

&lt;p&gt;Not all websites or applications resemble a multi-layered cake, and not every site requires a data layer. But web analytics are important for enterprises with some kind of a measurable objective. The data layer is therefore generally crucial to have in such cases and is useful in tandem with a tag management solution such as &lt;a href="https://analyticsinstitute.hashnode.dev/how-to-set-up-google-tag-manager-gtm-on-your-website-quickly"&gt;Google Tag Manager&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Alright, so you just want to see a data layer? Go to any e-commerce site, and open the console in your developer tools. I'm using a Mac, so I can use the shortcut command+option+j to get it to pop up. Alternatively, you can right-click, click 'inspect', then click the 'console' tab. In my case, I'm going to go to lego.com (because Legos are fun!). When I open the browser console, I can type 'dataLayer' (this is case sensitive!)...and voila! Do you see that JavaScript object?&lt;/p&gt;

&lt;p&gt;Now, let's try to do something as someone who is pretending (or not pretending!) to eventually make a purchase. Add a product to the cart, then view your shopping cart. Check the data layer again by typing 'dataLayer' in the console. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--ZDaaizY7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/do83dk5becx8kkspw18m.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--ZDaaizY7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/do83dk5becx8kkspw18m.png" alt="datalayer" width="880" height="659"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;As you can see, data from your add-to-cart action is now being expressed in the data layer. We can see, for example that I'm on the "shopping_cart" page, that I'm in the "US" region, I'm not logged in, and that the items in my cart total $729.98. You can also apparently see that I do not meet the Lego definition of a 'vip', whatever that is. 😭🤣&lt;/p&gt;

&lt;p&gt;Why is it important that you are able to use the data layer to see data? Well, if you're running an e-commerce business, you might want to capture all that data for your strategic analyses as well as to enable your marketing platforms to optimize on such data.&lt;/p&gt;

&lt;p&gt;Now that you know what the data layer is, we can begin discussing how we can work with it to achieve our enterprise goals - all to be covered in other posts.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;This post was originally published by &lt;a href="https://analyticsinstitute.hashnode.dev/what-is-the-data-layer-and-why-do-you-need-it"&gt;Analytics Institute on Hashnode&lt;/a&gt; on Nov 26 2022.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>analytics</category>
      <category>webdev</category>
      <category>javascript</category>
      <category>datascience</category>
    </item>
    <item>
      <title>How to Set Up Google Tag Manager (GTM) on Your Website Quickly</title>
      <dc:creator>Anna</dc:creator>
      <pubDate>Sun, 25 Dec 2022 23:55:02 +0000</pubDate>
      <link>https://forem.com/analyticsinstitute/how-to-set-up-google-tag-manager-gtm-on-your-website-quickly-4c9o</link>
      <guid>https://forem.com/analyticsinstitute/how-to-set-up-google-tag-manager-gtm-on-your-website-quickly-4c9o</guid>
      <description>&lt;p&gt;&lt;strong&gt;First&lt;/strong&gt; - &lt;em&gt;What on earth is Google Tag Manager? Google Tag Manager (GTM) is a &lt;a href="https://en.wikipedia.org/wiki/Tag_management_system"&gt;tag management system&lt;/a&gt;. A 'tag', in this context, is essentially a relatively small fragment of code. Google Tag Manager allows us to easily add, update, and determine how these fragments of code are used in the measurement of user behavior on a website or app. Measuring user behavior is central to digital marketing for A/B testing, campaign data analysis, conversion tracking, and more. Many tags are built into GTM, allowing non-technical people to make many tracking implementations without the help of a developer. For more complex implementations, custom HTML and JavaScript can be used in GTM.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Here's how to install GTM on your website.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Create a GTM account&lt;/strong&gt;&lt;br&gt;
Before you set up Google Tag Manager (GTM) on your website, you need to make sure you have an account, so go to &lt;a href="https://analyticsinstitute.hashnode.dev/how-to-set-up-google-tag-manager-gtm-on-your-website-quickly#:~:text=tagmanager.google.com"&gt;tagmanager.google.com&lt;/a&gt; create one there.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Set up a web container&lt;/strong&gt;&lt;br&gt;
When you’re done, you’ll also need to create a new GTM “container” where all the tags for your site are kept or contained, as the name suggests. In the case of setting GTM up for your website, you’ll want to select “Web” as your target platform. In the menu, you will see other target platform options such as iOS, Android, AMP, and Server, which we will cover in other blog posts.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Find the GTM installation snippets and copy&lt;/strong&gt;&lt;br&gt;
Once you have the container set up, make sure you are on the “Workspace” tab on the upper-left hand side of your GTM interface. When you’re there, you will be able to see a container ID on the right-hand side of the interface in the form of a link, pre-fixed with “GTM-“.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--gz91TncM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5v9jw3dyoc8k7zokmra3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--gz91TncM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5v9jw3dyoc8k7zokmra3.png" alt="GTM workspace" width="880" height="512"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Click that link, and a modal titled “Install Google Tag Manager” will pop up with further instructions on your next steps.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--yz6a4h8k--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/u1lgvjtkmtncqf7k1jgm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--yz6a4h8k--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/u1lgvjtkmtncqf7k1jgm.png" alt="GTM installation code" width="880" height="680"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Start with the first snippet: highlight and copy it into your clipboard, or simply click the copy icon on the top right.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4. Paste the snippets into your website’s base code&lt;/strong&gt;&lt;br&gt;
Depending on how you have your website set up, the process of pasting the GTM installation snippets may vary somewhat. If you are working only with hard code, and not using a popular content management system like WordPress, for example, you’ll have to find the relevant files in your website code and insert the snippets in the right locations. As indicated in the GTM documentation, simply paste the code snippets in their respective places in the &lt;code&gt;head&lt;/code&gt; and &lt;code&gt;body&lt;/code&gt; of your code.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Okay, that makes sense – you might be thinking – but my website is powered by Wordpress. Now what?&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Install Google Tag Manager on your WordPress Website&lt;/strong&gt;&lt;br&gt;
Finding the head and body of your website may not be so straightforward to everyone working with WordPress. Luckily, there is a WordPress plugin that you can install called 'Insert Headers and Footers by WPBeginner'. So, go to your WordPress sidebar, click Plugins and search for this plugin. Next, install it!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--m8zRCHgJ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qjaw4s1go2p2gccoviat.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--m8zRCHgJ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qjaw4s1go2p2gccoviat.png" alt="Wordpress plugin - Insert Headers and Footers by WPBeginner" width="880" height="453"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Now that it’s installed, go to &lt;strong&gt;Settings&lt;/strong&gt;, then click &lt;strong&gt;Insert Headers and Footers&lt;/strong&gt;. Voila! This is where you will have to paste your GTM installation snippets. After pasting them, remember to save them.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--uN-7iOq0--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/8lnvgvehhlaalq8dlr7q.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--uN-7iOq0--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/8lnvgvehhlaalq8dlr7q.png" alt="Insert GTM into wordpress site" width="880" height="680"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you are using a platform other than WordPress, the process is the same. Find a way on that platform to be able to insert the GTM installation snippets into the &lt;code&gt;header&lt;/code&gt; and &lt;code&gt;body&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Checking Your Setup&lt;/strong&gt; &lt;br&gt;
Now, how can you quickly verify that you now have GTM set up on your website? One way is to check that your first tag fires. But even before doing this, you could download a Chrome extension called Google Tag Assistant (Legacy). Go to your website, enable Google Tag Assistant, then refresh your page. If GTM is properly set up, you’ll see it next to the green tag icon like below – congrats!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Yc5NGNea--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jr3lh5acus899405he2m.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Yc5NGNea--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jr3lh5acus899405he2m.png" alt="Google tag assistant legacy" width="880" height="507"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;This post was originally published by &lt;a href="https://analyticsinstitute.hashnode.dev/how-to-set-up-google-tag-manager-gtm-on-your-website-quickly"&gt;Analytics Institute on Hashnode&lt;/a&gt; on Nov 25 2022&lt;/em&gt;.&lt;/p&gt;

</description>
      <category>googletagmanager</category>
      <category>analytics</category>
      <category>marketing</category>
      <category>javascript</category>
    </item>
    <item>
      <title>Why and How to Start Using Xcode to Build Your React Native iOS Apps ASAP</title>
      <dc:creator>Anna</dc:creator>
      <pubDate>Thu, 22 Oct 2020 05:31:58 +0000</pubDate>
      <link>https://forem.com/analyticsinstitute/why-and-how-to-start-using-xcode-to-build-your-react-native-ios-apps-3edj</link>
      <guid>https://forem.com/analyticsinstitute/why-and-how-to-start-using-xcode-to-build-your-react-native-ios-apps-3edj</guid>
      <description>&lt;p&gt;Many of us involved in mobile application development with React Native have been used to working on &lt;a href="https://expo.io/"&gt;Expo&lt;/a&gt;. This makes complete sense since the React Native &lt;a href="https://reactnative.dev/docs/environment-setup"&gt;documentation&lt;/a&gt; itself has indicated that it is the easiest way to get started. &lt;/p&gt;

&lt;p&gt;That said, if you are interested in eventually publishing your app on the App store, you might want to start getting used to working with Xcode. That’s because starting April 2021, all iOS and iPadOS apps submitted to the App Store will be required to be built using Xcode 12. &lt;/p&gt;

&lt;p&gt;So, let’s get started. If you don’t already have Node and Watchman installed, you should get them via &lt;a href="https://brew.sh/"&gt;Homebrew&lt;/a&gt; using the following terminal commands:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;brew install node&lt;br&gt;
brew install watchman&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;While you probably have these as a React Native developer, it is a good idea to at least install Node 10 or later. &lt;/p&gt;

&lt;p&gt;Of course, you’ll need to install Xcode. You can just download it from the app store &lt;a href="https://apps.apple.com/us/app/xcode/id497799835?mt=12"&gt;here&lt;/a&gt;. Next, you’ll need CocoaPods, which manages library dependencies for your projects when using Xcode. So, install using:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;sudo gem install cocoapods&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Now we’re ready – are you exiting to get started on your new app? To start a new project, navigate to where you would like to save it, then in your terminal type,&lt;/p&gt;

&lt;p&gt;&lt;code&gt;npx react-native init &amp;lt;the name of your new project&amp;gt;&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Your project will have starter boilerplate code, which you will be able to see once you open it in your code editor. To run your project and view it in a mobile device simulator, simply type,&lt;/p&gt;

&lt;p&gt;&lt;code&gt;npx react-native start&lt;br&gt;
npx react-native run-ios&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Now you are ready to start programming and to see your work on the simulator. Happy coding!&lt;/p&gt;

</description>
      <category>react</category>
      <category>reactnative</category>
      <category>javascript</category>
      <category>ios</category>
    </item>
  </channel>
</rss>
