<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Raghav Vashisht on Medium]]></title>
        <description><![CDATA[Stories by Raghav Vashisht on Medium]]></description>
        <link>https://medium.com/@rvs36?source=rss-587328c72bf7------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*OqqzE890DnSfGNnK8R-nDA.jpeg</url>
            <title>Stories by Raghav Vashisht on Medium</title>
            <link>https://medium.com/@rvs36?source=rss-587328c72bf7------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 09:01:30 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@rvs36/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[My french driving license story]]></title>
            <link>https://rvs36.medium.com/my-french-driving-license-story-836db670f93f?source=rss-587328c72bf7------2</link>
            <guid isPermaLink="false">https://medium.com/p/836db670f93f</guid>
            <category><![CDATA[licensing]]></category>
            <category><![CDATA[driving]]></category>
            <category><![CDATA[france]]></category>
            <category><![CDATA[life]]></category>
            <category><![CDATA[lessons]]></category>
            <dc:creator><![CDATA[Raghav Vashisht]]></dc:creator>
            <pubDate>Sat, 19 Nov 2022 02:00:08 GMT</pubDate>
            <atom:updated>2022-11-19T13:45:08.957Z</atom:updated>
            <content:encoded><![CDATA[<h4>In this infotainment article, I will share my experience over the last 2 years to get the French “Permis de Conduire.” Sharing this with you as I think it will be worth the time to share knowledge, resources, and links, and above all will be an interesting read. So tighten your seat belts and, On y va!</h4><h3>The background</h3><p>I have been driving in India and UK since 2012, and have driven around 20,000+ in Indian cities like Delhi, Noida, and GURUGRAM (if you know, you know). So, I thought driving in France would be easy peasy 🤣</p><p>So the rule says that you can <a href="https://www.indiancommunitytoulouse.org/blogs/Driving-License/driving-in-france-with-an-indian-dl-idp.html">drive in France on a Foreign license</a> as long as you are on a short-term visa or a student visa. Just carry an attested translation of your (Indian, in my case) license.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*je2rFr5OJtDNkxtD.jpg" /><figcaption>Chateau de Chantilly — Clicked during one of the road trips during the masters.</figcaption></figure><p>So during my master&#39;s in Paris, I could rent a car from sites like getaround.com and go anywhere I liked. But like all good things, the masters finished, and so did my privilege to drive around. And since I could not simply exchange my Indian license with a French one, I embarked on a 2-year long journey to get a french driving license…</p><h3>The procedure to get a license</h3><p>So the steps are fairly simple:</p><ul><li><a href="https://ants.gouv.fr/monespace/s-inscrire">Register </a>to get a NEPH number</li><li>Clear the theory exam</li><li>Do the driving classes</li><li>Pass the practical exam</li></ul><p>Now, there are two main ways of getting a license — go to a driving school, <em>“Auto Ecole” </em>which will take care of everything for you, or do things on your own as a “<em>Candidat Libre”.</em></p><p>Now for the driving schools, you have 2main categories:</p><ul><li>French Speaking schools (those found in your neighborhood)</li><li>English Speaking Schools — like Zipee and Fehrenbach in the Paris region</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/300/0*TmRi9mJoXhpD_HDk.jpg" /><figcaption>French law ask every candidate to undergo at least some training before appearing for the practical exam.</figcaption></figure><p>As a “<em>Candidat Libre” </em>you need to go to online schools — like Ornicar, Stych, Lepermislibre, etc. to do some driving classes.</p><p>In the following sections, you will find all the steps I took in my journey of getting this the ‘permis de conduire’.</p><h3>Step 0: Gather all the info</h3><p>If you are going through an Auto Ecole, they will give you all the study material and will answer all your questions. Although most things will be in French, be ready to brush up on your french skills.</p><p>However — If you are a Candi Libre like me, you need to gather all the resources on the internet.</p><p>For starters, here are some useful links I found:</p><ul><li><a href="https://www.facebook.com/groups/206199943590115/">Applying for a French Driving Licence</a> — I can not recommend this group enough! As an Anglophone in France, this is one place where you will find everything. The group is run by a one-woman army <a href="https://www.facebook.com/groups/206199943590115/user/100000055774665/">Kim Cranstoun</a><strong>, </strong>kudos to her!</li><li><a href="https://www.indiancommunitytoulouse.org/blogs/driving-licence.html">Blog by ICT</a>- a step-by-step guide to getting a license in France.</li><li><a href="https://www.youtube.com/@conduiteonline">Conduite Online </a>— excellent videos on how to park your car.</li><li><a href="https://www.youtube.com/@fcdautoecole">Fcd Autoecole</a> — a good collection of videos to understand how things work on french roads.</li><li><a href="https://www.ornikar.com/">Ornikar </a>— and other similar websites of online schools have some free as some free online theory exam material and mock tests.</li></ul><h3>Step 1: Start preparing for the theory exam</h3><p>Be it auto ecole or candi lib, the first hurdle is to pass the theory exam, also known as (épreuve théorique commune or ETG). The format is 40 MCQs — you must get at least 35 correct to pass.</p><p>The exam is held at most post offices. And there are appointments available almost every day. Here is a <a href="https://www.service-public.fr/particuliers/vosdroits/F33694#:~:text=5Passer%20l&#39;examen&amp;text=Avant%20de%20commencer%20l&#39;%C3%A9preuve,35%20r%C3%A9ponses%20justes%20ou%20plus.">link </a>to read more about it.</p><p>I registered with Ornikar to get their study material and did some mock tests before writing the final exam(s).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*8C3yeQ-4qTk-JlOZ" /><figcaption>Written Exam: first of many hurdles</figcaption></figure><ul><li>I score 31 on the first attempt.</li><li>I figured out the sections I was weak in — working on those — got 28 this time, thanks to some weird french words I found in the exam.</li><li>I tried again and got 34 this time- unlucky me!</li><li>And finally, I passed the exam with 38/40 — everything worked out on that day.</li></ul><p>Be it the lack of french knowledge understanding or being overconfident at exams — <strong>It took me 4, yes, </strong>four attempts to finally pass it.</p><p>Please be aware some times (which was definitely NOT the case for me), the exam can be surprisingly more difficult than the mock tests.</p><p>Often, I think taking an exam would have been a better option. I will leave that to your judgment of french to see if that is an option you should consider.</p><p><strong>Phew, they definitely test your persistence!</strong></p><h3>Step 2: First driving lesson</h3><p>So after passing the theory exam, it was time to go for the first driving lesson. Having driven already in France, I was fairly confident about it.</p><p>And I impressed the evaluator from Ornikar, he recommended 5 hours of driving lessons, and I was ready for the exam!</p><p>He just asked me to register on the Candilib portal. And he told me to do it fast as there was a long waiting on the portal.</p><h3>Step 3: The long wait….</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/760/0*l64LKlZlLkEkyzqZ.jpg" /></figure><p>What started as an abnormally long waiting period to get an exam with the prefecture for a practical exam date was a classical example of french bureaucracy!</p><p>This was anything but normal — I tried different things — from paying a <a href="https://www.candibot.fr/">third party</a> to booking a slot for me using web scripts. or taking things in my hand to try to use <a href="https://github.com/tritus/candilibre">someone’s script I found on GitHub</a> to get a place for me.</p><p><strong>But nothing worked out!</strong></p><p>At some time, almost 100,000 people were waiting for an appointment with the prefectures across France for the practical exam.</p><p>There were various petitions signed up. Some protests, but nothing changed.</p><p><strong>UPDATE:</strong></p><blockquote>Now that people have suffered through it enough. The government has scrapped the old system for the following departments — 45–75–77–78–91–92–93–94 and 95. And if you live in these departments, you can simply book an appointment now on the new <strong>RdvPermis</strong> platform.</blockquote><h3>Step 4: The system is screwed up; let us take another route</h3><p>After waiting for a year and seeing that doing things on my own was not working out, I decided to move my file to a Driving School.</p><p>They insisted that you give an exam through them I had to do minimum of 20 hours. Not left with many options, I decided to go for it.</p><p>I sometimes think I could have done that from the very beginning. But</p><blockquote>Life is only 20% of what happens to you, and 80% is decided by how you react to it.</blockquote><p>Anyways, I did the 20 hours, appeared in the driving exam, and FAILED!</p><p>I made a very small mistake of stopping the car at a round point after the line, and the inspector mercilessly decided that it was an ‘eliminatory mistake’.</p><p><strong>PRACTICE MAKES PERFECT!</strong></p><p>I did not give up, did another 10 hours, and appeared in the exam after 1 month, and this time, I passed with a score of 29.5/30. I feel immensely proud when I see my evaluation sheet 😁😁</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/761/1*JGE3rCDvSnO6iuPqtG5m7g.jpeg" /></figure><p>So here are some takeaways from my driving school experience:</p><ul><li><strong>Ornikar instructors are amazing </strong>— If you get the chance, try to drive with Ornikar instructors. Since they work on a rating and active feedback mechanism, they are way better than the ones you find at driving schools.</li><li><strong>Choose wisely — </strong>Not every instructor is the same at the auto ecole. Ask for the instructor who has the best chemistry with you. Remember — if you don’t ask it, you won’t get it.</li><li>Learn from youtube — And like most things in life, Youtube has the best teachers in the world, and you should definitely leverage that on technical things like how to park your car, etc.</li></ul><h4>Step 5: Finally, I passed!!! Time to buy a car 🚗</h4><p>Last week I bought my mine own car. But I am more proud of the fact that I am now driving it with a hard-earned French driving license.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*-RBcs1LjbWoV3-Fo.jpeg" /><figcaption>Interiors of my Peugeot 208 — I deserve this after 2 years of hard work!</figcaption></figure><h3><strong>How much money did it cost me</strong></h3><p>So depending on the route you choose to take — English Speaking Schools are super expensive, as they need to provide you with a translator for the written exam. And the online ones are the cheapest as they are supposed to be ‘disruptive’ in this ‘rotting system.’</p><p>For me personally, I took 10 hours with Ornicar, 400 Euros, and 4 attempts of theory exam — 150 Euros. The first shot of driving 30 hours — 1000 Euros, and then another 10 hours since I failed once — 500 Euros. <strong>So almost 2000 Euros.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Q2dShw75lN5ebFD3kEIVMw.png" /><figcaption>Just a photo of me driving around in Paris</figcaption></figure><p>But I was naive and did a lot of things stupidly if you do things smartly (that is the reason I am writing this)— go to an auto Ecole (now since the online ones have appointments available), do everything with the same school, do not rush for an exam date — you should be all good in almost about 1000 Euros.</p><p>I hope this article was useful for you, and best of luck with your Permis de Conduire Journey. If you have any questions leverage the power of social media channels- we still live in a very helpful world.</p><h3><strong>Liked this article?</strong></h3><p>If you liked this article, please follow my medium profile and drop some claps to this article.</p><p>It will encourage me to finish part 2 of this series — where I reflect on this 2 years journey and identify the things I did (I wish I had not) and some things I could not do and I wish someone would have told me already.</p><p>And I answer the big question of whether to pass with an auto school, online school, or go on your own for the French Driving License.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=836db670f93f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Everything you need to know about RDBMS vs. OLAP]]></title>
            <link>https://medium.com/atoti/everything-you-need-to-know-about-rdbms-vs-olap-965e853ceb02?source=rss-587328c72bf7------2</link>
            <guid isPermaLink="false">https://medium.com/p/965e853ceb02</guid>
            <category><![CDATA[olap]]></category>
            <category><![CDATA[rdbms]]></category>
            <category><![CDATA[atoti]]></category>
            <category><![CDATA[cube]]></category>
            <category><![CDATA[data]]></category>
            <dc:creator><![CDATA[Raghav Vashisht]]></dc:creator>
            <pubDate>Mon, 16 May 2022 10:32:21 GMT</pubDate>
            <atom:updated>2024-06-26T16:57:47.339Z</atom:updated>
            <content:encoded><![CDATA[<p>This article will explore the two big players in the data processing game- OLAP and RDBMS.</p><p>Different people have different opinions, understanding, and biases. Let us make a vis-a-vis comparison of the two technologies, OLAP and RDBMS.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=technology"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*JVeGwMuJgCsUWo6ZAU0-8g.png" /></a></figure><h3>Part 1: Let us start with some definitions (yawn…)</h3><h4>DBMS</h4><p>Database Management System refers to any sort of database.</p><h4>RDBMS</h4><p>Relational DBMS is the most commonly used database-e.g., Oracle, SQL Server and is characterized by the organization of data into tables, with primary keys that allow for unique identification of rows in each table and foreign keys that allow tables to relate to other tables.</p><blockquote>The only non-relational databases in common use are NoSQL databases, e.g. MongoDB.</blockquote><h4>OLTP</h4><p>Online Transaction Processing is the predominant use case for an RDBMS. RDBMS design often emphasizes data normalization for the sake of efficient transaction processing.</p><h4>OLAP</h4><p>Online Analytical Processing is an analytical activity like count, aggregation, mean, sum, etc., generally performed on databases that have been de-normalized to facilitate OLAP.</p><p>These de-normalized databases are often referred to as data warehouses. There are different variations of OLAP that exist -<a href="https://www.activeviam.com/blog/olap-molap-rolap-or-holap-olap-acronyms-explained/">MOLAP, ROLAP, or HOLAP.</a></p><h3>Data lake, Data warehouse, and Data marts</h3><p>Before diving deep into the RDBS and OLAP comparison, let us try and have a sense of the bigger picture around data lakes, data warehouses, and data marts.</p><h4>Data warehouse</h4><p>Data warehouses will frequently work<a href="https://www.zuar.com/blog/data-mart-vs-data-warehouse-vs-database-vs-data-lake/#:~:text=Data%20lakes%20are%20better%20for,stored%20in%20different%20user%20areas."> in conjunction with</a> an operational data store (<a href="https://en.wikipedia.org/wiki/Operational_data_store">ODS</a>) to ‘warehouse’ data captured by the various databases used by the business.</p><p>The method of extracting data from the database, transforming it in the ODS, and loading it into the data warehouse is an example of the extract-transform-load (<a href="https://www.zuar.com/blog/elt-and-etl-tools-and-processing/">ETL</a>) process or the similar <a href="https://www.zuar.com/blog/etl-vs-elt-whats-the-difference/">ELT process</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/0*4uVUkB5msTHyJpWP.jpg" /><figcaption>Credits: <a href="https://www.zuar.com/blog/data-mart-vs-data-warehouse-vs-database-vs-data-lake/#:~:text=Data%20lakes%20are%20better%20for,stored%20in%20different%20user%20areas.">Zuar</a></figcaption></figure><h4>Data Mart</h4><p>A data mart is very similar to a data warehouse. Like a data warehouse, the data mart will maintain and house cleaned data ready for analysis. However, unlike a data warehouse, the scope of visibility is limited.</p><p>A data mart supplies <strong>subject-oriented data</strong> necessary to support a specific business unit.</p><h4>Data Lake</h4><p>A <a href="https://www.forbes.com/sites/bernardmarr/2018/08/27/what-is-a-data-lake-a-super-simple-explanation-for-anyone/">data lake</a> stores an organization’s raw and processed (unstructured and structured) data at both large and small scales.</p><p>Unlike a data warehouse or database, a data lake captures <strong>anything </strong>the organization deems valuable for future use. With the advent of machine learning, more and more companies are trying to build data lakes.</p><p>A data lake can store literally any type of data - images, videos, PDFs, anything!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/0*JSo62G_2VgQir8X-.jpg" /><figcaption>Credits: <a href="https://www.zuar.com/blog/data-mart-vs-data-warehouse-vs-database-vs-data-lake/#:~:text=Data%20lakes%20are%20better%20for,stored%20in%20different%20user%20areas.">Zuar</a></figcaption></figure><h3>Part 2: The interesting part — Going beyond the definitions</h3><p>In the next couple of sections, we will now try to unravel OLAP and RDBMS -understand how they work, going through the pros and cons of each one.</p><h3>OLAP</h3><p>Online analytical processing (OLAP) is a technology that organizes large business databases and supports complex analysis.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tA0fzANjaBFdNQ0ezeNwCA.png" /><figcaption>An OLAP cube</figcaption></figure><p>It can be used to perform complex analytical queries without negatively affecting transactional systems.</p><h4>OLAP Cube</h4><p>An OLAP cube is a data structure that overcomes the limitations of relational databases by providing rapid analysis of data.</p><p>OLAP cubes can display and sum large amounts of data while also providing users with searchable access to any data points so that the data can be rolled up, sliced, and diced as needed to handle the widest variety of questions that are relevant to a user’s area of interest.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/453/0*atKWHPqkPdnbZyP6" /><figcaption>Credits: <a href="https://docs.microsoft.com/en-us/system-center/scsm/olap-cubes-overview?view=sc-sm-2022#:~:text=An%20OLAP%20cube%2C%20also%20known,shown%20in%20the%20following%20illustration.">Microsoft</a></figcaption></figure><p>Cubes can display and sum large amounts of data while also providing users with searchable access to any data points.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/583/1*Jy3duGHBaT_fxFdJz6E39Q.png" /><figcaption>A cube <a href="https://github.com/atoti/notebooks/blob/main/notebooks/01-use-cases/other-industries/food-processing/main.ipynb">schema created by atoti</a></figcaption></figure><p>OLAP cubes can also be used to <a href="https://www.activeviam.com/blog/technology-en/streaming-olap-handling-data-in-motion/">handle streaming data</a>. Also, there have been advances around making a <a href="https://www.activeviam.com/blog/technology-en/olap-and-oltp-hybrid-systems-fact-or-fiction/">hybrid of OLAP and OLTP.</a></p><h4>How to Query OLAP Cubes? What is MDX?</h4><p>Multidimensional Expressions (MDX) is a <a href="https://en.wikipedia.org/wiki/Query_language">query language</a> for <a href="https://en.wikipedia.org/wiki/Online_analytical_processing">online analytical processing</a> (OLAP) using a <a href="https://en.wikipedia.org/wiki/Database_management_system">database management system</a>. Much like <a href="https://en.wikipedia.org/wiki/SQL">SQL</a>, it is a query language for <a href="https://en.wikipedia.org/wiki/OLAP_cube">OLAP cubes</a>.</p><p>MDX provides a specialized syntax for querying and manipulating the multidimensional data stored in <a href="https://en.wikipedia.org/wiki/OLAP_cube">OLAP cubes</a>. It is also a calculation language with syntax similar to spreadsheet formulas.</p><blockquote>While it is possible to translate some of MDX syntax into traditional SQL, it would frequently require the synthesis of clumsy SQL expressions, even for very simple MDX expressions.</blockquote><p><strong>So SQL is not exclusively for RDBM Systems; check out </strong><a href="https://www.kdnuggets.com/2018/09/olap-queries-sql-refresher.html"><strong>this article</strong></a><strong> to learn how OLAP queries can be implemented in SQL.</strong></p><p>For example — The <strong>CUBE </strong>operator computes a union of GROUP BY’s on every subset of the specified attribute types.</p><h3>RDBMS</h3><p>A <a href="https://www.hitechwhizz.com/2021/04/6-advantages-and-disadvantages-limitations-benefits-of-relational-database.html"><strong>Relational database</strong></a> is a kind of management system in which tables are used to store data. Once the data is stored inside the table, it can be retrieved anytime.</p><h4>What are examples of Relational databases?</h4><p>These tables use primary keys and foreign keys to make them interrelated to each other. Thus, it saves time to a greater extent.</p><p>Some examples of relational databases are Oracle, SQL Server, DB2, and Access.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/835/1*dWZz7zKypeD30VubqO0aTw.png" /><figcaption>In a relational database, relationships between data items are expressed using tables. Interdependencies among these tables are expressed by data values rather than by pointers. This allows a high degree of data independence.</figcaption></figure><h4><strong>How to Query RDBMS?</strong></h4><p>A database management system (DBMS) that incorporates the relational-data model, normally including a Structured Query Language (SQL) application programming interface.</p><h3>So in conclusion</h3><blockquote><a href="https://dba.stackexchange.com/questions/5794/how-does-an-olap-cube-database-differ-from-an-rdbms">An RDBMS would be a spreadsheet and a cube would be a Pivotable.</a> Cube allows you to define dimensions (things you’d need to filter on like Dates,regions), hierarchies (eg months within a year, countries for Continents,…) and measures and rules on how these measures relate with the dimensions.</blockquote><h3>Part 3: The Juxtaposition</h3><p>In the last part of this article, we will start with a vis-a-vis comparison of OLAP and RDBMS. Then we will go through the pros and cons of each of them. And finally, we will talk about how to take the OLAP cubes to the next level with <a href="https://www.atoti.io/">atoti</a>.</p><h3>OLAP vs. RDBMS: Summary</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0zVztvAdtyTlAwQh6-hTug.png" /></figure><h3>Pros and Cons of Relational Database</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-T9VQWiIcxMDkwe6l8AoCg.png" /></figure><h4>Advantages of Using OLAP</h4><ol><li><strong>Business Focused:</strong> OLAP enables one to <a href="https://ecapitaladvisors.com/blog/why-olap/">organize data in a multidimensional model</a> that makes it easy for business users to understand the data and to use it in a business context, such as a budget.</li><li><strong>Pre-Calculated Aggregations:</strong> OLAP systems are so swift because they pre-aggregate values that would need to be computed on the fly in a traditional relational database system. In an OLAP system, the analytic capabilities are independent of how the data is presented. The analytic calculations are centrally stored in the metadata for the system, not in each report.</li><li><strong>Trustworthy Data and Calculations: </strong>Unlike RDBMS,<strong> </strong>OLAP systems centralize data and calculations, ensuring a single source of data for all end users. OLAP systems ensure end users have access to consistently defined data and calculations to support BI (Single Source of Truth).</li><li><strong>Flexible, Self-Service Reporting: </strong>The best report designers and builders usually come from within the business community itself because they know what is needed. OLAP systems enable business users to query data and create reports using tools that are natural for them to use.</li><li><strong>Speed of thought Analysis/Ad Hoc Analysis: </strong>OLAP systems respond much faster to end-user queries than relational databases that do not capitalize on OLAP technology. Quick response times are possible because OLAP systems pre-aggregate data. Pre-aggregation means that there is no need for many time-consuming calculations when an end-user query is processed. In addition, OLAP systems are optimized for business calculations, so calculations take less time to execute.</li><li><strong>”What-if” Scenarios: </strong>You can analyze not only the actual data but also create different “what-if” scenarios and change the data you work with while also ensuring the actual cube data is not overridden or lost.</li><li><strong>Flat Learning Curve: </strong>Working with OLAP can be more simplistic because it works on more business hierarchies and levels and hence resonates with the business user.</li></ol><p><a href="https://atoti.io/">atoti </a>augments the advantages of OLAP and diminishes its disadvantages.</p><h4>Disadvantages of using OLAP</h4><ol><li><strong>Memory considerations: </strong>If you run all data warehouse extraction, transformation, and load (ETL) operations and OLAP cube functions on one server, carefully consider the memory needs of the operating system, data warehouse, and SSAS to ensure that the server can handle all the data-intensive operations that can run concurrently. This is especially important because processing OLAP cubes is a memory-intensive operation.</li><li><strong>OLAP is relational: </strong>The main problem of such a system is that the structure must be defined in advance. It means the number of columns in the table and data types should be precalculated before table creation. For quick results, it can cause some difficulties.</li><li><strong>Computation capability: </strong>Some systems provide lack of computational power. That greatly reduces the flexibility of the OLAP tool. Analyzers are limited to a narrow and small area, unable to analyze freely, and even have to resort to a third party to perform this kind of calculation. In such business computing, OLAP is often left in an awkward situation.</li></ol><h3>Part 4: atoti &amp; OLAP</h3><p>If you planning to do a more business-focused BI, OLAP could be the preferred tool.</p><p>How can you take the OLAP cube to the next level with atoti? Let us go through the features of atoti and see how it augments the advantages of OLAP and diminishes its disadvantages.</p><h4>Lets us see how atoti augments OLAP</h4><ol><li><strong>Flat Learning Curve: </strong>atoti is backed up by an intuitive UI, where you can perform most functions by a simple drag and drop.</li></ol><p>2. <strong>”What-if” Scenarios: </strong>You can create multiple what-if scenarios and compare them side by side.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*d166usBl_LNWK0DI" /></figure><p>3. <strong>Business Focussed: </strong>atoti is focused on the needs of the business. It gives you the flexibility to play with the data.</p><p>4. <strong>Security: </strong>One of the main concerns around OLAP is security and access control. With Atoti+, you can control which user has control over which type of data.</p><p>5. <strong>Memory considerations: </strong>atoti can optimize your existing computing capacity to do superfast calculations. atoti also supports almost all cloud-based computing to perform analytics on Big Data in real-time.</p><h4>Sounds Interesting?</h4><p>We invite you to <a href="https://docs.atoti.io/latest/index.html">try atoti now</a>; you can also check out our <a href="https://github.com/atoti/atoti">GitHub gallery to see atoti in action</a>.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=technology"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*4VPqJ0BCewWMWZLXmm0F6Q.png" /></a></figure><h4>Flat learning Curve?</h4><p>We also have a <a href="https://www.youtube.com/c/atoti/videos">YouTube page</a> to walk you through all the atoti tutorials. You can also check out the <a href="https://www.atoti.io/category/guides/">tutorial sections of the atoti website</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=965e853ceb02" width="1" height="1" alt=""><hr><p><a href="https://medium.com/atoti/everything-you-need-to-know-about-rdbms-vs-olap-965e853ceb02">Everything you need to know about RDBMS vs. OLAP</a> was originally published in <a href="https://medium.com/atoti">Atoti</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Do you know what changed in the latest version of atoti?]]></title>
            <link>https://medium.com/atoti/do-you-know-what-changed-in-the-latest-version-of-atoti-9fc69520caad?source=rss-587328c72bf7------2</link>
            <guid isPermaLink="false">https://medium.com/p/9fc69520caad</guid>
            <dc:creator><![CDATA[Raghav Vashisht]]></dc:creator>
            <pubDate>Wed, 27 Apr 2022 15:40:29 GMT</pubDate>
            <atom:updated>2024-06-26T16:54:09.284Z</atom:updated>
            <content:encoded><![CDATA[<p>We recently released atoti 0.6.5. The latest version of atoti comes with a whole lot of features and makes playing with data much more intuitive and straightforward.</p><blockquote>“We cannot become what we want by remaining what we are.” — Max de Pree</blockquote><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=guide"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*t6An-5CL31sL0B0FWLSThw.png" /></a></figure><p>In order to give our users a state-of-the-art experience using atoti, we continuously improve and release new versions of atoti.</p><p>A few weeks ago, we released atoti v0.6.5. The latest version of atoti comes with more intuitive programming features. In this article, I will share with you what has changed in the latest version.</p><p>Hence we will zoom in on the <a href="https://docs.atoti.io/latest/releases/0.6.5.html#:~:text=Changed,-Creating%20and%20configuring">changed </a>section in the <a href="https://docs.atoti.io/latest/releases/0.6.5.html">changelog</a>.</p><h3>Creating and configuring a session</h3><p>Previously, in order to create a session, we had to define a config that had all the configuration details.</p><p>Here is a sample snippet to create and configure a sample in the <strong>older versions</strong> of atoti.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/6b5181e1b69023af5f5b188905a27d7d/href">https://medium.com/media/6b5181e1b69023af5f5b188905a27d7d/href</a></iframe><p>And now creating and configuring a session is done by passing the <strong>corresponding parameters to atoti.Session.__init__()</strong>.</p><p>So in the latest atoti 0.6.5, we can create and configure a session like:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/32dccf6651c5858c326f1188a7de98d4/href">https://medium.com/media/32dccf6651c5858c326f1188a7de98d4/href</a></iframe><h3>H2 Database</h3><p>In the latest version of atoti, passing a <a href="https://docs.atoti.io/latest/lib/atoti/atoti.config.user_content_storage_config.html#atoti.UserContentStorageConfig"><strong>atoti.UserContentStorageConfig</strong></a> pointing to a local H2 database will automatically migrate the database to H2 v2 format during session startup.</p><p>So the latest version of atoti now uses, the v2 of the <a href="https://www.h2database.com/html/main.html">H2 database</a> — the very fast, open-source, JDBC API, which had embedded and server modes and comes with disk-based or in-memory databases options.</p><h3>Conclusion</h3><p>We hope this article was helpful for you to understand what has changed in the latest version of atoti.</p><p>So, what are you waiting for?</p><p>Migrate to the latest version of atoti now!</p><p>These changes can be seen in action in our <a href="https://github.com/atoti/atoti">notebook gallery</a> which has the notebooks running on the latest atoti version 0.6.5.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=guide"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*HWiOfjB2HBZoafw0G92RUQ.png" /></a></figure><p>We are constantly improving our library to provide a better experience for our users. For that reason, we have prepared a wide variety of examples across different topics in our <a href="https://github.com/atoti/atoti">atoti notebook gallery</a> for your reference.</p><p>Finally, we love to hear from you!</p><p>If you have any questions or you want to share your own use case with atoti, reach out to us on the <a href="https://github.com/atoti/atoti/discussions">atoti GitHub discussions forum</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9fc69520caad" width="1" height="1" alt=""><hr><p><a href="https://medium.com/atoti/do-you-know-what-changed-in-the-latest-version-of-atoti-9fc69520caad">Do you know what changed in the latest version of atoti?</a> was originally published in <a href="https://medium.com/atoti">Atoti</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Unravel price elasticity of demand with atoti]]></title>
            <link>https://medium.com/atoti/unravel-price-elasticity-of-demand-with-atoti-4c18d0b26c59?source=rss-587328c72bf7------2</link>
            <guid isPermaLink="false">https://medium.com/p/4c18d0b26c59</guid>
            <category><![CDATA[atoti]]></category>
            <category><![CDATA[price-elasticity]]></category>
            <category><![CDATA[price-analysis]]></category>
            <category><![CDATA[insurance]]></category>
            <category><![CDATA[machine-learning]]></category>
            <dc:creator><![CDATA[Raghav Vashisht]]></dc:creator>
            <pubDate>Fri, 11 Feb 2022 11:07:52 GMT</pubDate>
            <atom:updated>2024-06-26T16:38:18.277Z</atom:updated>
            <content:encoded><![CDATA[<h4>In this article, we will use the price elasticity of the demand-based model built with atoti to construe the relation between the quote price and policy sale for automobile insurance policies.</h4><h3>Overview</h3><p>Price elasticity is the key to understanding product demand and how consumers react to changes in market price.</p><p>Price elasticity can be seen across a wide plethora of domains from retail to insurance. Here we will build a predictive model on the quotes data from an automobile insurer to predict whether a customer will buy the insurance policy or not.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=use-cases"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*JVeGwMuJgCsUWo6ZAU0-8g.png" /></a></figure><p>Then we will use atoti atoti to build a price elasticity of demand model on top of the predictive model to identify the different buckets of customers based on their price sensitivity. We will then create different what-if scenarios on the price and sales probability from the predictive model.</p><h3>What is the price elasticity?</h3><p>Price elasticity of demand is a simple measurement of the change in consumption of a product in relation to a change in its price.</p><p>In general, the availability of a substitute for a product affects its elasticity. If there are no good substitutes and the product is necessary, demand won’t change when the price goes up, making it inelastic.</p><ul><li>A <strong>good is elastic</strong> if a price change causes a substantial change in demand or supply.</li><li>A <strong>good is inelastic</strong> if a price change does not cause demand or supply to change very much.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/1*XfQKJxq8IXqMavosMZddjA.png" /></figure><h3>Cross Price Elasticity of Demand</h3><p>The <a href="https://en.wikipedia.org/wiki/Cross_elasticity_of_demand">Cross Elasticity of Demand</a> measures the response of the quantity demanded of a good when there is a price change of another good.</p><p>Cross price elasticity can measure either complementary products or substitute products. A negative cross-price elasticity means that the two products are substitutes for one another, and the increase in price for one would lead to higher consumer demand for the other.</p><p>Conversely, a product complement exists when the increase in the price of product #1 leads to a decrease in the demand for product #2, as the two products are used in conjunction with one another.</p><p>Cross price elasticity of demand can also be an interesting approach to study what happens when the competitors increase their quote price, but here we are not focussing on the probability of being affected by changes in other products.</p><h3>Insurance Pricing explained</h3><p><em>You can skip through this section if you already have some understanding of how insurance companies price their policies.</em></p><p>Every insurance company has two components of the quote price it gives to its customer for the insurance policy.</p><p>The first component is a <strong>technical premium</strong>, it is the bare minimum amount it needs to book to cover the cost of claims. Then there is another component the profit component, this is the part we will try to optimize using the price elasticity models.</p><h4>Insurance Pricing is more complex than it seems</h4><p>The inelasticity of customers can be attributed to the need of the customers and the <strong>urgency of buying a policy.</strong> For example, a policy that lapses tomorrow will be renewed by a customer with the company which issues the policy fastest, no matter what price we quote for the renewal.</p><p>The <strong>customer could also be inelastic for specialty lines,</strong> for example for a customized car, an insurer can quote a higher price because no other competitor is willing to underwrite that policy.</p><h4>Price elasticity in insurance</h4><p>The price elasticity models in insurance can hence be classified into two categories. The first one is for normal automobiles, in this case, the models would be like in the retail industry for nonessential goods— the customer would be quite sensitive to the price.</p><p>In the second type of price elasticity model, for specialty automobile lines, the model’s behavior would be like for the essential goods, so the customer would not be price-sensitive, and in some cases even more likely to buy with the price increase, because we are underwriting a policy which is very niche.</p><blockquote>And in cases of speciality lines, the quoted price of the policy can be proportional to the probability of the customer buying the policy. It simply means that more risky or niche a policy is, lesser is the competition to underwrite it and hence less options the customer has, which means the probability of buying that policy is much higher.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*aE02Q6wYvNXi8SN3yc_1cg.png" /><figcaption>Price optimization explained</figcaption></figure><h3>Our Use Case: The dataset and predictive modeling</h3><p>So now since we have understood the basics of price elasticity and how it applies to the insurance industry. Let us talk about the use case at hand.</p><h4>Dataset</h4><p>We used the Kaggle dataset on the <a href="https://www.kaggle.com/ranja7/vehicle-insurance-customer-data">automobile insurance quotes and sales</a> and further augmented it using<a href="https://www.atoti.io/synthetic-data-generation-test-your-proof-of-concept-without-the-data/"> synthetic data generation</a>.</p><p>We split the data into — train, validation, and test dataset. Here is a screenshot of the dataset:</p><figure><img alt="Data header" src="https://cdn-images-1.medium.com/max/986/1*YWqW4aTjMzjBw3Yh6Tj9Ww.png" /></figure><h4>Predictive models and Evaluation Metrics</h4><p>From the above dataset, we did some feature engineering and built some predictive models to predict whether a given customer will buy a policy or not.</p><p>We tried various classification models and evaluated the performance of the there models on different metrics. The results are summarized below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/821/1*w2z0yVISnLSPNXf4bFmZ6w.png" /></figure><p>Here, the key metric for us to consider is — recall and then F1 score, because we do not want to miss out on the people who will buy the policy by predicting they will not.</p><p>The best model hence was XGBoost with a recall of 0.95 and an f1 score of 0.93. So we shall use this model for making predictions on the test dataset.</p><p>On the test dataset, it gave us an f1 of 0.93 and a recall of 0.94.</p><h4>Feature importance</h4><p>Now we have established the predictive power of the models, the next step would be to understand which features contribute the most to this predictive power. For the price elasticity model to work, the price of the quote should be one of the most important features.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/864/1*l1svB-JUrWsckmB7qtsbYQ.png" /><figcaption>Feature importance from XgBoost</figcaption></figure><p>Hence, <strong>quote price is the most important factor </strong>for the XGBoost model. It is important to note that the price of the quote has <strong>4 times</strong> more predictive power than the second next feature and <strong>10 times</strong> more predictive than the 10th feature in the list.</p><p>Just to confirm this finding, we run an OLS model and find the results and see how much is the coefficient of quote price.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/858/1*C1kFOZpq-vxl1tJiPaxbeQ.png" /></figure><p>It is important to note the <strong>sign of the coefficient of quote price is positive, which means that the price positively correlated</strong> to the probability to sales.</p><h3>The spectacular widgets of atoti</h3><p>Price elasticity is all about altering the quote price and seeing the impact it has on the sale of the policy. From a business perspective, it would be really interesting to apply various rules of scenarios and what if and put them in the model and get the results.</p><p>Here, we will define the KPIs and visualize them on the prediction on the test dataset. In the next step, we will create different create then see how the KPIs are impacted under these scenarios.</p><h4>Defining and visualizations KPIs on the test dataset</h4><p>We created various KPIs in atoti around the proportion of sales captured and the proportion of revenue captured. With atoti, you can create new measures on the fly using the existing measures.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6v_K6wzc77Zk_4gBwWp5SA.png" /><figcaption>Sales proportion by channel and coverage type</figcaption></figure><p>Once the widgets were created, we used the atoti BI app in the Jupyterlab notebook to create different widgets.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1oUk6WlWCwRpmaDgq7CDTA.png" /><figcaption>Revenue realized by sales and policy types</figcaption></figure><p>Thanks to atoti, we can create interactive and useful visualizations without any coding — simply drag and drop the measures and hierarchies of interest.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*geu5kJ1d9Vj1il6Pu8OjYQ.png" /><figcaption>Sales by policy type</figcaption></figure><h4>Creating scenarios in atoti</h4><p>Simulations are a way to compare several scenarios and do what-if analysis. This helps understanding how changing the source data or a piece of the model impacts the key indicators.</p><p>In atoti, the data model is made of measures chained together. A simulation can be seen as changing one part of the model, either its source data or one of its measure definitions, and then evaluating how it impacts the following measures.</p><p><strong>We can create two main types of scenarios in atoti:</strong></p><ul><li><strong>Source simulation:</strong> Simulation of the source and using the entire pipeline on the new data source.</li><li><strong>Parameter simulation:</strong> Simulation a parameter based on some metrics and creating the whole pipeline from it.</li></ul><p>Note that all the existing measures are immediately available on the new data in both the above simulations.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kJXZ8ckQHFxlnIYbVrsIfg.png" /><figcaption>Everything else is shared between the scenarios and <strong>has not been duplicated: source scenarios in atoti are memory-efficient.</strong></figcaption></figure><h4><strong>Creating the price elasticity model: Interaction between atoti and the machine learning model</strong></h4><p>As step one, we have loaded the test dataset along with predictions in atoti. And then we did visualizations on the KPIs using that dataset.</p><p>Now, we will create a scenario based on the quote price and then do a prediction using the new price. This data will be loaded back in atoti as a source scenario and hence, the visualizations will be updated on that price simulation.</p><p>So, the session now will have multiple scenarios and the only differences between them are the lines corresponding to the products with better prices, everything else is shared between the scenarios and <strong>has not been duplicated: source scenarios in atoti are memory-efficient.</strong></p><p>Here we are considering the following scenarios:</p><ol><li><strong>The Pareto Principle — </strong>Increase the price by 20% for all the policies for which sales probability is more than 80% Drop the price by 20% for policies that have a probability to be bought less than 20%. This will affect the most price-sensitive customers from the customers who have not bought the policy.<br>On the other hand, this will help identify the most price-insensitive customers from the customers who have actually bought the policy.</li><li><strong>Boost Personal Auto and Basic Coverage — </strong>of all the policy types, personal auto, and basic coverage are the weakest sections. In this scenario, we will see what happens if we try to boost the personal auto lines by increasing the policy price by 25%? and the basic coverage by 15%.</li><li><strong>Geographic Improvements</strong> — In the states of Oregon and Washington, suburban areas are not performing well. So we can try and drop the prices by 10% for customers in rural areas of Oregon and drop by 15% in urban areas of Washington to see how price-sensitive the customers in the respective segment are.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xsh0O-XgrXx-pBTdNXg7-A.png" /><figcaption>Scenarios: Sales proportion by channel and coverage type</figcaption></figure><p>After creating the scenarios, we can see that the widgets have been automatically updated. Now we can visualize the widgets and see the impacts on our KPIs under these scenarios. Here are the updated widgets:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*R-ahV_8CnK9luA6XWFPrug.png" /><figcaption>Scenarios for revenue</figcaption></figure><p>Finally, all the information can be compiled in the form of a dashboard and shared with other users. The dashboard we created has different tabs and filers for the scenarios and cases.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KaRahaeHHAXRUlUht8qrfA.gif" /><figcaption>Interactive atoti dashboard with all the scenarios and KPIs</figcaption></figure><p><strong>Access Controlling atoti Dashboards</strong></p><p>Access control at folders and dashboards level using roles. Users from different departments and teams will be able to access the system. However, there may be dashboards that are team-specific and should not be accessible by others.</p><p>In this case, we can have a department and team-specific roles. Thereafter, business analysts or key users with the “ROLE_SHARE” access can now design dashboards and share them with their respective teams and departments.</p><p>You can know more about <a href="https://www.atoti.io/articles/secure-dashboards-with-access-control-on-the-data-atoti-to-atoti/">ROLE_SHARE and atoti+ here</a>.</p><h3>Conclusion</h3><p>In this article, we used atoti and a predictive model based on XGBosst classification to deduce the price elasticity of different customer buckets under various scenarios.</p><p>We saw above, how atoti can seamlessly integrate with a predictive model to create different what-if scenarios and hence, identify the price-sensitive and insensitive customers across different segments.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=use-cases"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*4VPqJ0BCewWMWZLXmm0F6Q.png" /></a></figure><p>Now we would like to invite you to try for yourself how atoti can help you simplify what-if scenarios and the price elasticity of demand!</p><p>For the detailed source code and many other such interesting use cases, do check out the <a href="https://github.com/atoti/atoti">atoti notebook gallery</a> on GitHub. This notebook can be <a href="https://github.com/atoti/atoti/blob/main/03-use-cases/01-finance/insurance/price-elasticity/main.ipynb">accessed here</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4c18d0b26c59" width="1" height="1" alt=""><hr><p><a href="https://medium.com/atoti/unravel-price-elasticity-of-demand-with-atoti-4c18d0b26c59">Unravel price elasticity of demand with atoti</a> was originally published in <a href="https://medium.com/atoti">Atoti</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Boost Your Digital Marketing Strategy with a dashboard]]></title>
            <link>https://medium.com/atoti/boost-your-digital-marketing-strategy-with-a-dashboard-d0510c0ad162?source=rss-587328c72bf7------2</link>
            <guid isPermaLink="false">https://medium.com/p/d0510c0ad162</guid>
            <category><![CDATA[marketing-strategies]]></category>
            <category><![CDATA[digital-marketing]]></category>
            <category><![CDATA[kpi]]></category>
            <category><![CDATA[dashboard]]></category>
            <category><![CDATA[atoti]]></category>
            <dc:creator><![CDATA[Raghav Vashisht]]></dc:creator>
            <pubDate>Mon, 06 Dec 2021 17:24:58 GMT</pubDate>
            <atom:updated>2024-06-26T16:18:43.306Z</atom:updated>
            <content:encoded><![CDATA[<h3>Boost Your Digital Marketing Strategy with a Dashboard</h3><h4>Digital marketing is ubiquitous. Learn how you can get real and tangible results from your digital marketing campaign by building a dashboard that helps you to monitor the KPIs. Here, we will leverage the marketing campaign data using atoti and build a digital marketing dashboard from scratch.</h4><h3>Importance of Digital Marketing</h3><p>89% of Americans go online at least daily, and 31% are online almost constantly. As a marketer, it’s important to take advantage of the digital world with an online advertising presence by building a brand and providing a great customer experience that brings more potential customers.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=use-cases"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*JVeGwMuJgCsUWo6ZAU0-8g.png" /></a></figure><p><a href="https://mailchimp.com/marketing-glossary/digital-marketing/">Digital marketing</a>, also called online marketing, is the promotion of brands to connect with potential customers using the internet and other forms of digital communication. This includes email, social media, and web-based advertising, and text and multimedia messages as a marketing channel.</p><p>What are the b<a href="https://www.digitalmarketer.com/digital-marketing/">enefits of digital marketing</a>?</p><p>Having a strong digital presence will help you in multiple ways:</p><ul><li>It will make it easier to create awareness and engagement both before and after the sale</li><li>It will shorten the buyer’s journey by presenting the right offers at the right time</li></ul><h3><strong>Approach That Gets Real Results</strong></h3><p>So now that you understand the importance of digital marketing, the important thing is to optimize your strategy and recalibrate to see what is working and what is not. The best way to do so is to have a dashboard that reflects the Key Performance Indicators (KPIs) for various aspects of digital marketing.</p><p>This digital marketing dashboard, though high level, will let you deep-dive into the details of the metrics.</p><p>So, here we will learn which are the various datasets you can get from the various components of digital marketing and then how to build a dashboard from scratch combining all those siloed datasets.</p><blockquote>Hence, this article will also try to address the key issue faced by executives globally — to have a single platform to track their diverse KPIs.</blockquote><h3>Dataset</h3><p>In the digital marketing world, you will see many different datasets that come from various facets — Newsletters/Email Campaigns, Social media details — how your company’s followers have evolved over time. Then for social media, there is a dataset for the posts regarding likes, shares, and comments. Finally, we have the web analytics data from the website. This would be about the website visitors&#39; demographics, the top pages, etc.</p><h4>Dataset 1: Web data</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cfOfm9kR4WjJrMm-DmCcHA.png" /><figcaption>Screenshot for the data header captures in <a href="https://docs.atoti.io/latest/lib/atoti.session.html#atoti.session.Session.read_csv">atoti datastore.</a></figcaption></figure><h4>Dataset 2: Email Campaign/Newsletter Data</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6-sIlDs7ARyb_z_SB61SRg.png" /><figcaption>Screenshot for the data header captures in <a href="https://docs.atoti.io/latest/lib/atoti.session.html#atoti.session.Session.read_csv">atoti datastore.</a></figcaption></figure><h4>Dataset 3: Social Media Dataset</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7aTuoYxnLM8npScRswjnag.png" /><figcaption>Screenshot for the data header captures in <a href="https://docs.atoti.io/latest/lib/atoti.session.html#atoti.session.Session.read_csv">atoti datastore.</a></figcaption></figure><p><strong>Where did we get this data?</strong></p><p>In a real-world scenario, these datasets would have contained a lot of sensitive information about the company’s digital marketing strategy. And hence, would have been very hard to access.</p><p>So we have synthesized our own dataset. Here also, we have used the faker python library for the same. You can read about another article we published on <a href="https://www.atoti.io/articles/synthetic-data-generation-test-your-proof-of-concept-without-the-data/">Synthetic Data Generation</a> and its importance.</p><h3>Building the Digital Marketing Dashboard from siloed datasets.</h3><p>Here, as we have seen above, we will be analyzing the information from the various datasets one by one and then compiling it all in a dashboard.</p><h4>Email Campaigns</h4><p>The first section is on the various Email campaigns run by the company. Launching a marketing campaign without tracking its performance is like buying a car with a <em>punctured tire</em>. It will not get you anywhere.</p><p>Once you have launched an email campaign, you must follow the key metrics like How many people open your emails? How many people click your links? Which link gets the most clicks? Etc.</p><p>This information would help you to not only recalibrate current campaigns but also design and plan future campaigns taking these metrics into consideration.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ds4q7n0yDNq-pivAuqGy4A.png" /><figcaption>Click through and Open rate by customer domain.</figcaption></figure><p>Here, we see two main visualizations that we have created from the email dataset:</p><ul><li>The first one is on the click-through rate (CTR) and the open rate for the emails for customers in various domains; this could have been extrapolated for the customers in various geographies as well.</li><li>The second one is for the evolution of the total number of subscribers. This shows the net new subscribers; news subscribers minus people who unsubscribed.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*L3prdMSgqR8oOORvOG2bSQ.png" /><figcaption>Waterfall chart for total subscribers</figcaption></figure><blockquote><strong>Here it is important to not that with atoti we can create multiple cubes from the various datasets and then build a common dashboard with widgets from these cubes.</strong></blockquote><h4>Web Analytics</h4><p>The second section is web analytics, summarizing the performance of the website. In this section, we talk about the visitors to the company website. Who visited our website? Which page did they visit? How long did they stay on that page? From where were they redirected to our website?</p><p>This information can be useful to redesign the website to make sure that we are redirecting the visitors towards the target pages(buy/download etc.). Web analytics can also help us review the success of our various campaigns for ad words etc.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IicWginhflEMIsoLACSXeQ.png" /><figcaption>Weekly website visitors</figcaption></figure><p>Here also, we can see two main visualizations we created in atoti on the web analytics data:</p><ul><li>Weekly visitors- How many people visited our website from various sources like Ad, Direct, Organic search, etc.</li><li>Time Spent on various pages — Which are the top pages people are spending the most time on? And how many people are spending how much time on which page?</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YAwV5fZsL9d7WddDPEw3Zg.png" /><figcaption>Time spent on different webpages</figcaption></figure><h4>Social Media and Campaigns</h4><p>Finally, we have social media campaigns. Nowadays your social media presence is one of the most critical aspects of your company’s online presence.</p><p>Here, we had two datasets; the first one is on the posts — how many post have we shared, on which platform, how did the post perform in terms of likes, clicks, shares, etc. And then, there is a dataset for the various social media platforms to see the evolution of the followers on the different platforms over time.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/560/1*2jbKnAMtOEL-jDJQscZrhA.png" /><figcaption>atoti cube combining two datasets.</figcaption></figure><p>Here, we have created a cube combining these two data frames by the platform and date. And hence, we shall be building new visualizations based on this new cube.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ys-jNp7Kz97YFpoLzMzdSw.png" /><figcaption>Monthly post proportion by platform.</figcaption></figure><p>Here, we can see how much content we create on a monthly basis for various social media platforms. And then, in the second visualization, we can gauge the success of our posts by the number of shares on different platforms.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Kd48bnnkEKCavajtCv7ZgA.png" /><figcaption>Performance of various posts by the number of shares</figcaption></figure><h4>Merging the widgets in a dashboard.</h4><p>Finally, we combine all the above information coming from totally different data sources into a single dashboard.</p><p>This interactive dashboard has three main tabs for the three areas we explored — Social Media, newsletter, and web. Hence, this will enable the end-user to navigate to the area of their interest and follow all the KPIs in a single place.</p><p>Each page of this dashboard has multiple filters for time, social media platform, customer domain, etc. Hence, users can slice and dice the data as they want along the various axes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WmZ0Z763SLAQcxsqhmoBtQ.gif" /><figcaption>Digital Marketing Dashboard Built in atoti</figcaption></figure><h3>Conclusion:</h3><p>In this article, we have seen how to leverage the maximum potential of your digital marketing efforts by building a dashboard and monitoring all KPIs from a single place.</p><p>To achieve the same in a world without atoti would have meant juggling multiple platforms and (probably) missing the story those KPIs are trying to tell you!</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=use-cases"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*4VPqJ0BCewWMWZLXmm0F6Q.png" /></a></figure><p>For the detailed source code and many other interesting use cases, check out the <a href="https://github.com/atoti/atoti">atoti notebook gallery</a> on GitHub. This digital marketing dashboard can be found <a href="https://github.com/atoti/atoti/tree/main/03-use-cases/02-other-industries/digital-marketing-dashboard">here</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d0510c0ad162" width="1" height="1" alt=""><hr><p><a href="https://medium.com/atoti/boost-your-digital-marketing-strategy-with-a-dashboard-d0510c0ad162">Boost Your Digital Marketing Strategy with a dashboard</a> was originally published in <a href="https://medium.com/atoti">Atoti</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Synthetic data generation: test your proof of concept, without the data!]]></title>
            <link>https://medium.com/atoti/synthetic-data-generation-test-your-proof-of-concept-without-the-data-c76e6b65523?source=rss-587328c72bf7------2</link>
            <guid isPermaLink="false">https://medium.com/p/c76e6b65523</guid>
            <category><![CDATA[database]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[use-cases]]></category>
            <category><![CDATA[python]]></category>
            <category><![CDATA[data-generation]]></category>
            <dc:creator><![CDATA[Raghav Vashisht]]></dc:creator>
            <pubDate>Tue, 29 Jun 2021 22:22:12 GMT</pubDate>
            <atom:updated>2024-06-26T15:21:36.464Z</atom:updated>
            <content:encoded><![CDATA[<h4>In this article, learn one of the sought out skills for data scientists -how to generate random datasets. We will see why to synthetic data generation is important and we will explore the various Python libraries to generate synthetic data.</h4><h3>Introduction: Why Data Synthesis?</h3><h4>Testing proof of concept</h4><p>As a data scientist, you can benefit from data generation since it allows you to experiment with various ways of exploring datasets, algorithms, data visualization techniques or to validate assumptions about the behavior of some method against many different datasets of your choosing.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=use-cases"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*t6An-5CL31sL0B0FWLSThw.png" /></a></figure><p>When you have to test a Proof of concept, a tempting option is just to use real data. One small problem though is that production data is typically hard to obtain, even partially, and it is not getting easier with new <a href="https://www.datacamp.com/community/tutorials/generate-data-trumania">European laws about privacy and security.</a></p><h4>Data is indeed a scarce resource</h4><p>The algorithms, programming frameworks, and machine learning packages (or even tutorials and courses on how to learn these techniques) are not a scarce resource <a href="https://towardsdatascience.com/synthetic-data-generation-a-must-have-skill-for-new-data-scientists-915896c0c1ae">but high-quality data is</a>. And hence arises the need to generate your own dataset.</p><p>Let me also be very clear that, in this article, I am only talking about generating data for learning the purpose and not for running any commercial operation.</p><p>For a more extensive read on why generating random datasets is useful, head towards <a href="https://realimpactanalytics.com/en/news/why-synthetic-data-is-about-to-become-a-major-competitive-advantage">‘Why synthetic data is about to become a major competitive advantage’</a>.</p><h3>The benefits of having a synthetic dataset</h3><p>As the name suggests, quite obviously, a synthetic dataset is a repository of data that is generated programmatically. So, it is not collected by any real-life survey or experiment. Its main purpose, therefore, is to be flexible and rich enough to help an ML practitioner conduct fascinating experiments with various classification, regression, and clustering algorithms. <a href="https://towardsdatascience.com/synthetic-data-generation-a-must-have-skill-for-new-data-scientists-915896c0c1ae">Desired properties are</a>:</p><ul><li>It can be numerical, binary, or categorical (ordinal or non-ordinal),</li><li>The <strong>number of features and length of the dataset</strong> should be arbitrary</li><li>It should preferably be <strong>random</strong> and the user should be able to choose a wide variety of <strong>statistical distribution</strong> to base this data upon i.e. the underlying <strong>random process can be precisely controlled and tuned</strong>,</li><li>If it is used for classification algorithms, then the <strong>degree of class separation</strong> should be controllable to make the learning problem easy or hard,</li><li><strong>Random noise</strong> can be interjected in a controllable manner</li><li>For a regression problem, a complex, <strong>non-linear generative process</strong> can be used for sourcing the data.</li></ul><h3>Python libraries to synthesize the data</h3><h4>Faker</h4><p><a href="https://faker.readthedocs.io/en/master/">Faker</a> is a Python package that generates fake data for you. Whether you need to bootstrap your database, create good-looking XML documents, fill in your persistence to stress test it, or anonymize data taken from a production service, Faker is for you.</p><h4>Trumania</h4><p><a href="https://github.com/RealImpactAnalytics/trumania">Trumania </a>is a scenario-based random dataset generator library. Trumania is based on scenarios in order to address these shortcomings and generate more realistic datasets. As the scenario unfolds, various populations interact with each other, update their properties and emit logs. In Trumania, the generated datasets are typically time-series because <a href="https://www.datacamp.com/community/tutorials/generate-data-trumania">they result from the execution of a scenario</a> that unfolds over time.</p><h4>Pydbgen</h4><p>It is a lightweight, <a href="https://pydbgen.readthedocs.io/en/latest/#">pure-python library</a> to generate random useful entries (e.g. name, address, credit card number, date, time, company name, job title, license plate number, etc.) and save them in either Pandas data frame object, or as an SQLite table in a database file, or in an MS Excel file.</p><h4>Sympy</h4><p>We can build upon the <a href="https://www.sympy.org/en/index.html">SymPy library</a> and create functions similar to those available in scikit-learn but can generate regression and classification datasets with a symbolic expression of a high degree of complexity.</p><h4>Synthetic Data Vault (SDV)</h4><p>The workflow of the <a href="https://github.com/sdv-dev">SDV library</a> is shown below. A user provides the data and the schema and then fits a model to the data. At last, new synthetic data is obtained from the fitted model. Moreover, the SDV library allows the user to save a fitted model (model.save(&quot;model.pkl&quot;)) for any future use.</p><p>Check out this <a href="https://ealizadeh.com/blog/sdv-library-for-modeling-datasets">article </a>to see SDV in action.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*aVSxwHwJ4H6KTf6O" /><figcaption><a href="https://ealizadeh.com/blog/sdv-library-for-modeling-datasets">The SDV workflow</a></figcaption></figure><p>Many of these packages can generate plausible looking data for a <a href="https://blog.ouseful.info/2019/02/18/generating-fake-data-quick-roundup/">wide definition of <em>data</em></a>, although they won’t necessarily model the mess of the real data; (any mess you build in will be <em>a</em> model of messy data, but not necessarily a realistic one). This is something to bear in mind when testing.</p><blockquote>You should be particularly careful with how you use them if you are testing machine learning models against them, and expect weird things to happen if you make like Ouroboros and use them to <em>train</em> models.</blockquote><h3>Conclusion</h3><p>Synthetic data is a useful tool to safely share data for testing the scalability of algorithms and the <a href="https://www.riaktr.com/synthetic-data-become-major-competitive-advantage/">performance of new software</a>. It aims at reproducing specific properties of the data. Producing quality synthetic data is complicated because the more complex the system, the more difficult it is to keep track of all the features that need to be similar to real data.</p><p>We have synthesized the dataset for the U.S. automobile using the faker Python library mentioned above. Here is a snippet of the dataset we generated:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/924/0*_qju-LVuWuwCagpT.png" /></figure><p>This dataset is used to create the sales cube in atoti. You can read about the sales cube article <a href="https://www.atoti.io/articles/building-a-sales-cube-in-atoti/">here</a>.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=use-cases"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*HWiOfjB2HBZoafw0G92RUQ.png" /></a></figure><p>I hope you enjoyed reading the above article and you are all set to sort out your data problem by synthesizing it. Let us know about your use case of generating synthetic data, or that of creating a sales cube!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c76e6b65523" width="1" height="1" alt=""><hr><p><a href="https://medium.com/atoti/synthetic-data-generation-test-your-proof-of-concept-without-the-data-c76e6b65523">Synthetic data generation: test your proof of concept, without the data!</a> was originally published in <a href="https://medium.com/atoti">Atoti</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Building a Sales Cube in atoti]]></title>
            <link>https://medium.com/atoti/building-a-sales-cube-in-atoti-6da759a6604a?source=rss-587328c72bf7------2</link>
            <guid isPermaLink="false">https://medium.com/p/6da759a6604a</guid>
            <category><![CDATA[sales-cube]]></category>
            <category><![CDATA[olap]]></category>
            <category><![CDATA[use-cases]]></category>
            <category><![CDATA[business-intelligence]]></category>
            <category><![CDATA[dashboard]]></category>
            <dc:creator><![CDATA[Raghav Vashisht]]></dc:creator>
            <pubDate>Fri, 18 Jun 2021 13:54:50 GMT</pubDate>
            <atom:updated>2024-06-26T15:18:38.399Z</atom:updated>
            <content:encoded><![CDATA[<h4>We build a sales cube on top of automobile Data from the U.S. In this article, learn how to slice and dice the dataset across multiple axes — the customers, the cars, and the brands to find interesting KPIs and summarize the KPIs in an atoti dashboard.</h4><h3>PART 1: Sales Cube and how atoti can ‘boost’ it.</h3><h4>What is a Sales Cube?</h4><p>Sales cubes are used to report on sales transactions, specifically concerning posting sales order invoices and sales order packing slips. Sales cube datasets are self-containing and do not require users to create table profiles.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=use-cases"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*t6An-5CL31sL0B0FWLSThw.png" /></a></figure><p>Various units of measure can be incorporated into a sales cube report to ensure that the quantity is correct, like using a SUM, MEAN or COUNT value.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Iw67931sM59YU0ZspJC1-A.png" /><figcaption>Example of a <a href="https://www.researchgate.net/publication/3297481_Using_datacube_aggregates_for_approximate_querying_and_deviation_detection#pf2">three-dimensional data cube with sales data.</a> (a)The entire data set. (b) Aggregated values for the selected portion of the data set (i.e., the sales of women’s jeans in New York)</figcaption></figure><h4>Dimensions, Measures, and Hierarchies explained.</h4><p>Here we will use the sales cube data in atoti to slice and dice the data. The sale cube shares the concepts of Hierarchies, Levels, and Measures with the multidimensional analysis or OLAP.</p><p>Once we have the dataset, we transform it into a data cube so that the dataset has multiple dimensions; unlike the stereotype idea of a cube, the data cube need not be in just 3 dimensions. It can be in as many dimensions as the number of variables.</p><h4>Dimensions</h4><p>Typical cube <strong>dimensions </strong>are Time, Customers, Products, Locations, Employees, Projects, etc. Use dimensions that are best suited to your business domain.</p><blockquote>Each dimension can have either just a detailed level of all dimension members or you can define hierarchy with several levels.</blockquote><p>For example, the <em>Customer</em> dimension could have <em>Country</em>, <em>State,</em> and <em>Customer Name</em> levels. Typically each dimension has an <em>All</em> level with one <em>All</em> member, which aggregates all dimension members.</p><h4>Hierarchies</h4><p>The axes of the cube are called <strong>hierarchies</strong>. After an initial hierarchy has been created, you can define additional hierarchies for a single dimension of a cube. This enables you to have multiple possible drill paths for the same data.</p><h4>Measures</h4><p>Measures typically are integer or decimal values that can be accessed either at the detailed dimension member level or can be aggregated at higher dimension levels. Typical measure examples could be Sales amount, Units sold, Cost amount, Transaction count, etc.</p><blockquote>The purpose of the multidimensional analysis is to visualize some numeric indicators at specific coordinates of the cube. These indicators are the measures.</blockquote><p>An example of the measure would be the number of products sold. All measures are automatically aggregated (typically as a sum of detailed level values) in upper hierarchy levels. E.g., looking at Sales amount measure at the Country level will give the total sales amount for this country.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vWOI6ub7xUWkomlHZ2FtlA.png" /><figcaption>Example <a href="https://www.researchgate.net/figure/Example-dimension-hierarchies-on-two-dimensional-sales-data-a-The-entire-data-set-b_fig2_3297481">dimension hierarchies</a> on two-dimensional sales data. (a) The entire data set. (b) Aggregated values for the upper half of the data set.</figcaption></figure><h4>Sales Cube made easy by atoti:</h4><p>The above concept of creating a cube from a dataset and creating dimensions, measures, and hierarchies on that data to analyze is<a href="https://docs.atoti.io/latest/tutorial/tutorial.html"> the basics on which atoti works. </a>You have to create dimensions, measures, and hierarchies for any dataset being loaded in atoti.</p><p>atoti stores can handle more data than pandas DataFrame. pandas can start to slow down with datasets larger than a few GBs while atoti scales more efficiently.</p><blockquote>Using atoti, you can build an advanced data model using joins between stores. The data is not duplicated like when you perform a merge in pandas.</blockquote><p>atoti has embedded interactive data visualization tools to give you quick insights. The visualization is not frozen: you can build a dashboard and share it with other users who can still interact with it (for example, by adding filters). And there is no need to write code to define your graph!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EdAz_yMp8uTkwdn2Hlqb6g.png" /><figcaption>A <a href="https://docs.atoti.io/latest/tutorial/tutorial.html"><em>cube</em> is a multidimensional view of some data</a>, making it easy to explore, aggregate, filter, and compare.</figcaption></figure><h3>PART 2: The Dataset</h3><p>Here, for this analysis, we will use a dataset on car sales in the U.S. The dataset is synthesized by taking inspiration from the actual car sale numbers reported in the U.S. for <a href="https://www.goodcarbadcar.net/2021-us-vehicle-sales-figures-by-brand/">2018 and 2019</a> for three car brands- Audi, Mercedez Benz, and BMW.</p><h4>Data Tables</h4><p>Here, we consider car sale data in the US market. There are two data tables, one on the car level and another one on the customer level.</p><p>The customer-level data consists of a primary key as the <em>customer_id, </em>and there is demographic information like — <em>sex, age, job</em>, and the <em>city </em>and <em>state </em>of residence of the customer.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/569/1*aDefcaHxWc0EiZhCkZ9pwA.png" /><figcaption>The Customer level Data</figcaption></figure><p>Another data table is the car sales data; this dataset consists of the information about the car purchased by the customer, which the customer_id can identify<em>.</em></p><p>This table has information like:</p><p><em>Brand:</em> what was the brand of the car, here we are considering cars from Audi, BMW, and Mercedez-Benz. <em>Model: </em>For a given car maker, what was the model name. There is also information on <em>body_type, </em>i.e., Sedan, Hatchback, Estate, etc. Then there is information on<em> transmission, fuel, the car&#39;s color, the date of purchase, and type_of_contract</em> — whether it was a purchased or a leased car.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/924/1*Z20FplIg0B4sm76d53iyNQ.png" /><figcaption>Car level data</figcaption></figure><h4>Loading the data in atoti</h4><p>These tables are loaded into atoti as cars and customers&#39; datastore, and then they are joined on the customer ID. Here, an assumption is made is that one customer has bought one car. In the scenario when one customer has bought multiple cars, the functionality will not change.</p><p>The data from the two tables is then loaded in atoti, and a cube is created with the option to define hierarchies, levels, and measures as per the business requirement.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/656/1*WMlRGNMo4yL7UUHfLNrB7A.png" /><figcaption>Cube with multiple axes of the customer and car level.</figcaption></figure><h3>PART 3: Defining the KPIs and reporting it into the dashboard.</h3><p>Here we have done an analysis on three different aspects -in terms of the number of cars, the car sales break up by brand and model, and then a customer level analysis — i.e. the relation between the demographics and the cars. So let us see in detail the three analysis:</p><blockquote><em>UPDATE: The GIFs and code snippets in this article are based on an older version of atoti. We have released much smoother and even more functional dashboards and widgets with the latest version of atoti. Check out </em><a href="https://docs.atoti.io/latest/index.html"><em>this link</em></a><em> to see the documentation of the latest version of atoti.</em></blockquote><h3>Analysis 1: The number of cars sold</h3><p>In the first set of analyses, we will consider how many cars have been sold and slice and dice this number along the various axes. This includes a pivot table to get the number of cars sold and their total value on a monthly level.</p><p>Another KPI to look at would be the breakdown of the number of cars by the Body type and color in a TreeMap in atoti.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iNFFxudaswkxmHNBkWs2ow.png" /><figcaption>TreeMap in atoti</figcaption></figure><p>Another KPI to look at is the sale for the different body types in the two years being considered.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nPOX38LqjunDz1GN5X7Khw.png" /><figcaption>Sales of cars by body type and year</figcaption></figure><p>Finally, we put the above KPIs and widgets corresponding to them in a dashboard. The dashboard also has filters on state and brand. Hence, this will enable the user to find the sale of various car brands in different states by easily filtering on the state/brand of interest.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lkuFWf7EZz-ZDOgyZCg6eQ.gif" /><figcaption>Interactive dashboard to share sales cube results.</figcaption></figure><h3>Analysis 2: The Car sales breakup by brand and model.</h3><p>The next analysis focuses on finding the best and worst-performing models for each brand in sliced by fuel type and the type of sale etc.</p><p>This analysis can be seen as an extension of the 1st analysis done above. Here we plot the timeline for the number of cars and the value of cars sold.</p><p>And then, this information is loaded into another interactive dashboard that lets you choose the transmission and fuel consumption of the vehicles from all three brands and shows you the top model for that brand and the sales from the filtered category.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WBmrSFCUS2JJ7QBuqtPaig.gif" /></figure><h3>Analysis 3: Customers Level Analysis.</h3><p>Finally, we perform an analysis on the customer-level insights. We will create buckets from the age of the customers and on that to our original data store — thanks to atoti, all of this can be done on the fly!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/865/1*oV6OTgBqXJs3yr2dBNPt1w.png" /><figcaption>Adding age buckets to the datastore</figcaption></figure><p>Finally, we create the KPIs on the number of cars bought by the people in the various age buckets. And we plot it on a radar plot in atoti.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/1*ZWLIRyVOTxEL4ePGjsZ90Q.png" /></figure><p>Here, we also plotted the sales of the cars in terms of the number of cars and the total value of sales split by the customers’ gender.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*j-itwEKNV4Ueb7ylEtnHMw.png" /></figure><p>Putting the information in the dashboard can be shared with other users to find more deep insights on the customer bucket of interest.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iSmz6ky87SoSoIF4iwAloA.gif" /></figure><h3>Conclusion</h3><p>Here we learned what a sales cube is, and we built our own sales cube on a dataset on the U.S. automotive industry sales numbers. We saw how building a sales cube in atoti is much faster and easier than doing it otherwise.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=use-cases"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*HWiOfjB2HBZoafw0G92RUQ.png" /></a></figure><p>For the detailed source code and many other such interesting use cases, do check out the <a href="https://github.com/atoti/atoti">atoti notebook gallery</a> on GitHub. This sales cube analysis can be found <a href="https://github.com/atoti/atoti/blob/main/03-use-cases/02-other-industries/sales_cube/main.ipynb">here</a>.</p><p>If you have also used atoti to build a sales cube, please <a href="https://www.atoti.io/contact/">share your success story</a> with us, and we will share it with the atoti community.</p><p>Thanks for reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6da759a6604a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/atoti/building-a-sales-cube-in-atoti-6da759a6604a">Building a Sales Cube in atoti</a> was originally published in <a href="https://medium.com/atoti">Atoti</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The How-tos of atoti Dashboards]]></title>
            <link>https://medium.com/atoti/the-how-tos-of-atoti-dashboards-a0a55dc0e6f2?source=rss-587328c72bf7------2</link>
            <guid isPermaLink="false">https://medium.com/p/a0a55dc0e6f2</guid>
            <category><![CDATA[dashboard]]></category>
            <category><![CDATA[bi]]></category>
            <category><![CDATA[atoti]]></category>
            <category><![CDATA[how-to]]></category>
            <category><![CDATA[business-intelligence]]></category>
            <dc:creator><![CDATA[Raghav Vashisht]]></dc:creator>
            <pubDate>Tue, 18 May 2021 07:32:00 GMT</pubDate>
            <atom:updated>2024-06-26T15:05:18.581Z</atom:updated>
            <content:encoded><![CDATA[<h4>Follow us as we will walk you through the process of creating, saving, sharing, and persisting dashboards in atoti.</h4><p>Would you like to create a business intelligence web application with atoti?</p><p>Business intelligence tools are helpful to stay competitive. Organizations of every size and stage use BI tools to analyze, manage and visualize business data. It is extremely easy to create a business intelligence web application with <a href="https://www.atoti.io/">atoti</a>.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=guide"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*JVeGwMuJgCsUWo6ZAU0-8g.png" /></a></figure><h3>Creating a session</h3><p>First, let us create a session in atoti, this session will give us a web application without any cube or any data loaded into it.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/22913b8110d4bef7b08ea2649fe92dd5/href">https://medium.com/media/22913b8110d4bef7b08ea2649fe92dd5/href</a></iframe><p>And after running the above, you will get a link to go to the web application.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/326/1*7C6Z2qRaTcXW-J_aRohgdA.png" /></figure><p>Initially, your web application will look something like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6YCrmbN54EosShA7My3cng.png" /><figcaption>An atoti web application before the cube creation</figcaption></figure><h3>Getting the atoti cube up and running</h3><p>Before moving further, we need to now load the data into atoti and create a cube. Here we will use a preprocessed version of <a href="https://www.kaggle.com/lava18/google-play-store-apps">Google Play Store Apps data</a> from Kaggle to create a simple cube:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/87805db1fd1cbfab6edee73e0d773693/href">https://medium.com/media/87805db1fd1cbfab6edee73e0d773693/href</a></iframe><p>I will now be able to access the cube from the web application. And this cube will be used for creating a dashboard.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NJhQoCnmeveMH3hqegYDLA.gif" /></figure><p>Now you can choose the widgets of your choice and make the dashboard as per the KPIs required. atoti enables you to determine the complexity of the dashboard based on your use case, there is no limit to the number of widgets you can have in the dashboard.</p><p>When you are happy with the dashboard, it is time to share it with other users!</p><h3>Sharing the atoti web application</h3><p>Did you notice the web application is running on localhost?</p><p>For other users to access the web application, we will have to share the IP address of the machine where the notebook or Python script with atoti is running- it could be your own laptop as well as a virtual machine running into the cloud</p><p><strong>To see the IP address of machine atoti is deployed on:</strong></p><p>For MacOS/Linux follow these steps:</p><ol><li>Open a Terminal app.</li><li>Type <em>/sbin/ifconfig</em> this will list your IP address</li></ol><p>For Windows:</p><ol><li>Press Windows key. Start typing <em>cmd</em> and select Command Prompt from the menu.</li><li>Type <em>ipconfig</em> and press Enter. This will display your IP address.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VK5UGBEtQUyWE7mNNW4ZjQ.png" /></figure><p>If you are working on your workstation like me, then your user might be on the same network as you.</p><p>You will need to manage the firewall access for your users, hence it is recommended to fix a port for the atoti web application to run on.</p><p>You can do so by configuring the port as shown below:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/048d6a2bd5aea5621b068fd233d7daaa/href">https://medium.com/media/048d6a2bd5aea5621b068fd233d7daaa/href</a></iframe><p>The atoti web application is now accessible from the IP address at port 55707:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/943/1*BAI9l9HTwvrnYjiikGC9VA.png" /></figure><p>You can also run atoti on a server or a cloud instance. Check out the below articles for cloud deployments:</p><p><a href="https://www.atoti.io/the-ultimate-deployment-guide-for-atoti-on-aws-with-amazon-ec2/">The Ultimate deployment guide for atoti on AWS with Amazon EC2</a></p><p><a href="https://medium.com/atoti/how-to-deploy-docker-image-for-bi-dashboards-in-aws-469620d3b7e6">How to Deploy Docker image for BI Dashboards in AWS</a></p><h3>Saving dashboards</h3><p>During initial creation, the dashboard will be automatically saved when you give it a title. Your dashboard will be named “New dashboard” if you save without giving a title.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-bBUWEFO77ZmpXFqvPsgGQ.png" /></figure><p>Alternatively, rename the dashboard’s title at the top right corner of the dashboard or use “Save” to give your dashboard a name.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CgH_3yuk9P7hd81fHbq21w.gif" /></figure><h3>Persisting a Dashboard</h3><p>As of the current setup, you will lose the saved dashboards and widgets once the session is closed. To be able to save the dashboard and widgets and pick it from your left the last time, you need to persist your dashboards.</p><p>To persist atoti dashboards, we need to set the user_content_storage parameter in the session configuration as follows:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/68b95d5016871ea66b8f7c87bdb77176/href">https://medium.com/media/68b95d5016871ea66b8f7c87bdb77176/href</a></iframe><p>This will create an H2 database under the folder “content”:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CZvi8sJr32mZOfKWJE_GjQ.png" /><figcaption>Refer to atoti documentation for more <a href="https://docs.atoti.io/latest/lib/atoti.config.html#atoti.config.create_config">configuration options</a>.</figcaption></figure><h3>Sharing atoti dashboards</h3><p>Your users will be able to access the dashboards from the web application. However, if you would like to bring them to a specific dashboard, you can simply share its URL with the users.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*gdEJ0yFZbs4llvOIHf15jg.png" /></figure><h3>Deleting a dashboard</h3><p>If you did not like a dashboard you created and would like to remove it, you can delete the dashboards.</p><p>Simply right-click on the dashboard to be deleted and select the delete option.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*R29kRo2kSelPhH2ckg_4wA.png" /></figure><p>Click “Delete” on the message prompt.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/504/1*hwsRQKW-1ScSa-3PUrTamQ.png" /></figure><h3>Over to you</h3><p>If you design some creative and useful dashboards and are proud of your creation, we would be very excited to hear about your success story!</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=guide"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*4VPqJ0BCewWMWZLXmm0F6Q.png" /></a></figure><p>Share it with us and stand a chance to get featured on the official atoti <a href="https://www.linkedin.com/company/atoti">LinkedIn</a>, <a href="https://medium.com/atoti">Medium</a>, or <a href="https://twitter.com/atoti_io">Twitter </a>channels.</p><p>The notebook used in this article can be found in the <a href="https://github.com/atoti/atoti/blob/main/02-technical-guides/topcount/atoti.ipynb">atoti notebook gallery</a>.</p><p>If you are still facing some issues with the atoti dashboards, you can always reach out to the atoti community on <a href="https://github.com/atoti/atoti/discussions">GitHub Discussions</a> or <a href="https://github.com/atoti">Github</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a0a55dc0e6f2" width="1" height="1" alt=""><hr><p><a href="https://medium.com/atoti/the-how-tos-of-atoti-dashboards-a0a55dc0e6f2">The How-tos of atoti Dashboards</a> was originally published in <a href="https://medium.com/atoti">Atoti</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to reduce machine learning bias]]></title>
            <link>https://medium.com/atoti/how-to-reduce-machine-learning-bias-eb24923dd18e?source=rss-587328c72bf7------2</link>
            <guid isPermaLink="false">https://medium.com/p/eb24923dd18e</guid>
            <category><![CDATA[artificial-intelligence]]></category>
            <category><![CDATA[bias-in-ai]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[bias]]></category>
            <dc:creator><![CDATA[Raghav Vashisht]]></dc:creator>
            <pubDate>Tue, 02 Mar 2021 17:23:24 GMT</pubDate>
            <atom:updated>2024-06-26T14:41:51.536Z</atom:updated>
            <content:encoded><![CDATA[<h4>Machine learning and artificial intelligence are becoming more and more ubiquitous and an integral part of our lives. Along with the rise of machine learning and artificial intelligence, the concern around machine learning bias is also increasing.</h4><p>In this article, we will talk about one of the hot topics in Machine Learning Ethics — how to reduce machine learning bias. We shall also discuss the tools and techniques for the same.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=technology"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*t6An-5CL31sL0B0FWLSThw.png" /></a></figure><h3>Machine Learning Bias</h3><p>Machine learning bias, also sometimes known as bias in artificial intelligence, is a phenomenon that occurs when an algorithm produces results that are systemically prejudiced due to erroneous assumptions in the machine learning process.</p><blockquote>Bias could be prejudice in favor or against a person, group, or thing that is considered to be unfair.</blockquote><h3>Examples of machine learning bias</h3><p><strong>1.Word Embeddings: </strong>The introduction of word embedding was a revolution for various natural language understanding problem as they were able to capture the simple relationship between words:</p><pre><em>King — Man + Woman = Queen</em></pre><p>The same word embeddings were also captured the following relationships:</p><pre><em>Computer-programmer — Man + Woman = Home-Maker</em></pre><p><strong>2. Amazon’s AI recruiting tool: </strong>Amazon, a few years ago, scrapped an artificial-intelligence-based recruiting tool. Which <a href="https://www.reuters.com/article/us-amazon-com-jobs-automation-insight/amazon-scraps-secret-ai-recruiting-tool-that-showed-bias-against-women-idUSKCN1MK08G">reportedly</a> had taught itself that male candidates were preferable. It penalized resumes that included the word “women’s,” as in “women’s chess club captain.” And it also downgraded graduates of women’s colleges.</p><p>Amazon edited the programs to make them neutral to these particular terms. But that was no guarantee that the machines would not devise other ways of sorting candidates that could prove discriminatory.</p><p><strong>3. COMPAS (Correctional Offender Management Profiling for Alternative Sanctions): </strong>This is perhaps the most talked-about example of machine learning bias. COMPAS was an algorithm used in US court systems to predict the likelihood a defendant would become a recidivist. The model predicted<a href="https://towardsdatascience.com/real-life-examples-of-discriminating-artificial-intelligence-cae395a90070"> twice as many false positives for recidivism for black offenders (45%) than white offenders (23%)</a></p><p>Now we have understood machine learning bias seen the drastic impact it could have on our lives. Let us understand what the different types of biases or the different factors causing machine learning bias are.</p><h3><strong>Types/causes of machine learning bias</strong></h3><p><strong>Data Bias</strong></p><p>Suppose certain elements of a dataset are more heavily weighted and/or represented than others. Then the resulting machine learning bias could be attributed to the data.</p><blockquote><a href="https://lionbridge.ai/articles/7-types-of-data-bias-in-machine-learning/#:~:text=Data%20bias%20in%20machine%20learning%20is%20a%20type%20of%20error,accuracy%20levels,%20and%20analytical%20errors">A biased dataset does not accurately represent a model’s use case, resulting in skewed outcomes, low accuracy levels, and analytical errors</a>.</blockquote><p>Data bias can further be specified into the following types:</p><p>1. <strong>Sample bias/ Selection Bias: </strong>the data used is either not large enough or representative enough to teach the system.</p><p><em>For example,</em> If a facial recognition system trained primarily on images of white men. These models have considerably lower levels of accuracy with women and people of different ethnicities.</p><p>2. <strong>Prejudice Bias /Association Bias: </strong>the data used to train the system reflects existing prejudices, stereotypes, and faulty societal assumptions, thereby introducing those same real-world biases into the machine learning itself.</p><p><em>For example,</em> using data about medical professionals that includes only female nurses and male doctors would thereby perpetuate a real-world gender stereotype about healthcare workers in the computer system.</p><p>3. <strong>Exclusion Bias: </strong>it’s a case of deleting valuable data thought to be unimportant. It can also occur due to the systematic exclusion of certain information.</p><p><em>For example,</em> imagine you have a dataset of customer sales in America and Canada. 98% of the customers are from America, so you choose to delete the location data thinking it is irrelevant. However, this means your model will not pick up on the fact that your Canadian customers spend two times more.</p><p>4. <strong>Measurement bias: </strong>the data collected for training differs from that collected in the real world or when faulty measurements result in data distortion.</p><p><em>For example, </em>in image recognition datasets, where the training data is collected with one type of camera, but the production data is collected with a different camera. Measurement bias can also occur due to inconsistent annotation during the data labeling stage of a project.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/939/1*vhWsELfCCJ4S4NzUTlkQTQ.png" /></figure><p><strong>There could be other types of machine learning bias whose origins are NOT in data. Examples of such machine learning bias include:</strong></p><p><strong>1.</strong> <strong>Algorithm bias: </strong>when there’s a problem within the algorithm that performs the calculations that power the machine learning computations. Either the algorithm favors or unnecessarily opposes a certain section of the population.</p><p>2. <strong>Anchoring bias</strong>: occurs when choices on metrics and data are based on personal experience or preference for a specific set of data. By “anchoring” to this preference, models are built on the preferred set, which could be incomplete or even contain incorrect data leading to invalid results.</p><p>For example, if the facility collecting the data specializes in a particular demographic or comorbidity, the data set will be heavily weighted towards that information. If this set is then applied elsewhere, the generated model may recommend incorrect procedures or ignore possible outcomes because of the limited availability of the original data source.</p><p>3. <strong>Confirmation bias/Observer Bias:</strong> It leads to the tendency to choose source data or model results that align with currently held beliefs or hypotheses. The generated results and output of the model can also strengthen the end-user&#39;s confirmation bias, leading to bad outcomes.</p><h3><strong>Practices to reduce machine learning bias</strong></h3><p>The following are some of the best practices you can follow to reduce machine learning bias:</p><p>1. Select training data that is appropriately representative and large enough to counteract common types of machine learning bias, such as sample bias and prejudice bias.</p><p>2. Test and validate to ensure that machine learning systems&#39; results don’t reflect bias due to algorithms or the data sets.</p><p>3. Monitor machine learning systems as they perform their tasks to ensure biases don’t creep in overtime as the systems continue to learn as they work. <strong>Subpopulation analysis</strong> is one of the smarter ways to do monitor model performance over time.</p><p>4.<a href="https://lionbridge.ai/articles/7-types-of-data-bias-in-machine-learning/#:~:text=Data%20bias%20in%20machine%20learning%20is%20a%20type%20of%20error,accuracy%20levels,%20and%20analytical%20errors."> Use multi-pass annotation</a> for any project where data accuracy may be prone to bias. Examples of this include sentiment analysis, content moderation, and intent recognition.</p><h3><strong>Tools &amp; Techniques to detect &amp; reduce machine learning bias:</strong></h3><p>In addition to the above-mentioned practices, there exist a few tools and techniques which could help to detect machine learning bias, and in some cases, even remove it.</p><ol><li><strong>Google’s What-If tool</strong></li></ol><p><a href="https://pair-code.github.io/what-if-tool/get-started/">Google’s What-If Tool (WIT)</a> is an interactive tool that allows a user to visually investigate the machine learning bias. It provides a way to analyze data sets in addition to trained TensorFlow models.</p><p>One example of WIT is the ability to manually edit examples from a data set and see the effect of those changes through the associated model. It can also generate partial dependence plots to illustrate how predictions change when a feature is changed.</p><p>Once machine learning bias is detected, WIT can apply various fairness criteria to analyze the performance of the model (optimizing for group unawareness or equal opportunity).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*1fSDoO7ao-n-Z403.gif" /></figure><p><strong>2. IBM AI Fairness 360</strong></p><p><a href="https://aif360.mybluemix.net/resources#overview">AI Fairness 360 </a>from IBM is another toolkit for detecting and removing bias from machine learning models. AI Fairness 360 is an open-source toolkit and includes more than 70 fairness metrics and 10 bias mitigation algorithms that can help you detect bias and remove it.</p><p>Bias mitigation algorithms include optimized preprocessing, re-weighting, prejudice remover regularizer, and others. Metrics include <a href="https://developer.ibm.com/technologies/machine-learning/articles/machine-learning-and-bias/">Euclidean and Manhattan distance, statistical parity difference,</a> and many others.</p><p>The toolkit is designed to be open to permit researchers to add their own fairness metrics and migration algorithms.</p><p><strong>3. Subpopulation Analysis:</strong></p><p>Subpopulation analysis is the procedure of considering just a target subpopulation from the whole dataset and calculating the model evaluation metrics for that population. This type of analysis can help and identify if the model favors or discriminates against a certain section of the population.</p><p>One way to perform subpopulation analysis is with pandas by filtering the target subpopulation as a new data frame and then calculating the metric in consideration for each of those dataframes. Another smarter way of doing sub-population analysis is by using <a href="https://www.atoti.io/">atoti </a>to do sub-population analysis.</p><p>atoti <a href="https://docs.atoti.io/latest/tutorial/01-Basics.html">leverages the power of OLAP</a> to slice and dice the model predictions. Hence, the benefits of using atoti include:</p><ul><li>You can slice and dice the data as you want(make flexible data buckets)</li><li>It enables you to create buckets on the fly</li><li>You can calculate various metrics in a few clicks by leverage the power of the OLAP cubes</li></ul><p>You can check out <a href="https://github.com/atoti/atoti/blob/main/03-use-cases/02-other-industries/sub-population-analysis/main.ipynb">this notebook to get started with sub-population analysis</a> in atoti and see how it is better than the other methods.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9gN_u_xemvGTuwf9cP-SUQ.gif" /></figure><p><strong>4. debias-ml:</strong></p><p><a href="https://github.com/leenamurgai/debias-ml">debias-ml</a> is a practical, explainable and effective approach to reducing bias in machine learning algorithms.</p><p>DebiasML is a novel application of oversampling. Though popular for data imbalance problems, oversampling has not been adopted to address bias. When tested on the Adult UCI dataset, DebiasML outperforms Generative Adversarial Networks (GANs) on many dimensions. It results in a significantly higher F1 score (as much as +17%).</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=technology"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*HWiOfjB2HBZoafw0G92RUQ.png" /></a></figure><h3><strong>Conclusion:</strong></h3><p>Machine learning and Artificial Intelligence have shown great promise in self-driving cars, recognizing cancer in radiographs, and predicting whether a loan is safe or not(to name a few). But Machine learning and Artificial Intelligence come with their own benefits and challenges. One key challenge is the presence of bias in the classifications and predictions of machine learning.</p><p>These biases could actually do more bad than good. They have consequences based upon the decisions resulting from a machine learning model. Therefore, it’s important to understand how bias is introduced into machine learning models, how to test for it, and then how to remove it.</p><p>In this article, we discussed the various types of machine learning bias. Discussed the best practices to reduce machine learning bias. And finally enlisted some tools and techniques to detect and hence reduce machine learning bias.</p><p>Every week, we analyze the tweets in the data science community and publish <a href="https://medium.com/atoti/top-trends/home">a weekly report on top trending Twitter topics</a>.</p><p>Check out the top trends and see how frequently the topic of machine learning bias makes it to the list of top Twitter topics!</p><p>For other such interesting use cases, check out our <a href="https://github.com/atoti/atoti">GitHub</a> and <a href="https://medium.com/atoti">Medium</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eb24923dd18e" width="1" height="1" alt=""><hr><p><a href="https://medium.com/atoti/how-to-reduce-machine-learning-bias-eb24923dd18e">How to reduce machine learning bias</a> was originally published in <a href="https://medium.com/atoti">Atoti</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why Machine Learning models might fail in production]]></title>
            <link>https://medium.com/atoti/why-machine-learning-models-might-fail-in-production-54d660d4f064?source=rss-587328c72bf7------2</link>
            <guid isPermaLink="false">https://medium.com/p/54d660d4f064</guid>
            <category><![CDATA[bias]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[production]]></category>
            <dc:creator><![CDATA[Raghav Vashisht]]></dc:creator>
            <pubDate>Mon, 15 Feb 2021 14:34:20 GMT</pubDate>
            <atom:updated>2024-06-26T14:28:27.014Z</atom:updated>
            <content:encoded><![CDATA[<h4>This article shall be covering methodologies to do a quality check on the predictions from a machine learning model before you deploy it into production.</h4><p>It happens quite often that the Data Science team has spent, weeks even months understanding the data, perform state of the art Feature Engineering try the various machine learning and deep learning modeling techniques, performed tuning the hyperparameters, and then built the ULTIMATE model to make predictions.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=technology"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*t6An-5CL31sL0B0FWLSThw.png" /></a></figure><blockquote>And when this machine learning model is put into production, the business results are below par than the ones in the development conditions.</blockquote><p>We shall be using the subpopulation analysis technique on the model predictions and understand why it is important to see through these subpopulations and how to do such an analysis.</p><blockquote>UPDATE: The code snippets in this article are based on an older version of atoti. Some of these may not work with the latest version of atoti. Check out this link to see the documentation of the latest version of atoti.</blockquote><h3><strong>Why s</strong>ubpopulation analysis is <strong>important:</strong></h3><ul><li><strong>To see the business impact of the model predictions: </strong>It can be used to check if the model predicts well the various subclasses of the data. This becomes critically important for the subpopulation which contributes the most from the business perspective.</li><li><strong>To check if the model was trained on an unrepresentative dataset: </strong>It may sometimes happen that the dataset is used for training the ML model could be unrepresentative for a particular (minority subpopulation) of the actual dataset.</li></ul><p>As these subpopulations do not affect the model&#39;s overall score, these nuances are likely to slip through the standard machine learning evaluation criteria like calculation F1 Score, Accuracy, etc.</p><p>Here is an infographic to summarize the difference in the standard model evaluation techniques and the subpopulation analysis for model evaluation:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1sBvyeP75IT8Tg7euldbkg.png" /><figcaption>It is important to individually analyze model performance on the subpopulation of high-value customers.</figcaption></figure><h3><strong>How to perform such an analysis:</strong></h3><p>Though a subpopulation analysis can always be done with pandas by filtering the target subpopulation as a new data frame and then calculating the metric in consideration for each of those DataFrames.</p><p>Here we shall be leveraging the power of OLAP to slice and dice the model predictions. We shall be using <a href="https://www.atoti.io/"><strong>atoti</strong></a><strong> </strong>for the same, the benefit of using atoti over others is:</p><ul><li>You can slice and dice the data as you want(make flexible data buckets)</li><li>It enables you to create buckets on the fly</li><li>You can calculate various metrics in a few clicks by leveraging the power of the OLAP cubes</li></ul><h3>Use case:</h3><p>In this section, we shall consider a use case in the insurance industry and see the importance of analyzing the model prediction on subpopulations.</p><h4><strong>The dataset:</strong></h4><p>We have the customer list with their demographic details. The objective is to make predictions if the existing <strong>health insurance policyholders </strong>would be interested in <strong>vehicle insurance</strong> provided<strong> </strong>by the company.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7GM0dPP2QYpDDq8rcY-r8A.png" /><figcaption>Here one key feature from the data from a business perspective is the annual premium being paid by the customers.</figcaption></figure><blockquote>We can make the assumption that the people buying the most expensive health insurance are likely to be owning high-end cars and they would be equally valuable as a vehicle insurance customer.</blockquote><p>But this information about the premium might be seen as ‘insignificant’ from the machine learning perspective, as the feature may have little or no impact on the model predictions.</p><p>Hence, there is a chance that the predictions made by the model on the subcategory of people paying a high premium may see a significant drop without us noticing any drastic change in the overall performance of the model.</p><h4>Methodology</h4><p>As discussed, the problem with calculating the performance metrics on the whole dataset is that we miss the details about how the model is performing on the subpopulations (even the ones having a high business impact).</p><p>We load the predictions on data from the model and create a datastore from it, and then from datastore, we create a datacube.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/79234170ec7b3bdf9286356a697e9f0a/href">https://medium.com/media/79234170ec7b3bdf9286356a697e9f0a/href</a></iframe><p>Calculate the F1 Score and AUC scores by defining custom functions in atoti for both.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/23967064c1b99f00ab90050bd3666d3e/href">https://medium.com/media/23967064c1b99f00ab90050bd3666d3e/href</a></iframe><p>The benefit of defining the F1 and AUC in atoti is that we can perform slice and dice on the cube and do the calculations for the subpopulation as we have created a measure for these scores.</p><p>Here the subpopulation of interest is customers paying the maximum premium. So, we take the top 5% of the policyholders by the annual premium paid, and <strong>we mess up the predictions for this subpopulation by simply reversing the predictions.</strong></p><p><strong>The objective </strong>is to imitate a situation where the ML model has been able to learn the characteristics of this subpopulation due to:</p><ul><li>Data drift — The characteristic of the key customers has changed over time</li><li>Unrepresentative dataset — The model is trained on a non-representative dataset as found in the production</li></ul><p>Once we have imitates the situation when the target subpopulation has a bad result, but the majority has almost similar populations. We load this dataset into atoti and calculate the predictions on the various subpopulations based on the annual premium paid.</p><h4>Results:</h4><p>We create buckets for customers in various sections based on the premium paid.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7c31dcddfa0d9d04c9691dc8d447c024/href">https://medium.com/media/7c31dcddfa0d9d04c9691dc8d447c024/href</a></iframe><blockquote>Thanks to <strong>atoti</strong>, we can actually create new buckets on the fly for various variables and change modify them without actually having to rerun the whole pipeline again.</blockquote><p>Once we have created the added the new buckets, inspecting the F1 and AUC score on the buckets is as easy as:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/6778d0af8db5f557100066feee6d9c37/href">https://medium.com/media/6778d0af8db5f557100066feee6d9c37/href</a></iframe><p>We could see that once we messed up the predictions, there is just a drop of 0.03 in the overall AUC score and a drop of 0.02 in the overall F1 score. But for the target subpopulation, as expected, the AUC score drop from 0.79 to 0.23, and the F1 score drops from 0.43 to 0.03.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CrKYBJ-aen8v-PEZpczI9A.png" /></figure><p>If we were to just monitor the model&#39;s overall performance, we would have definitely missed such a significant drop in the key customer segment.</p><p>So it would be highly beneficial to monitor the various subpopulations to make sure that the model is not predicting an important segment of customers incorrectly or it is not discriminating against a particular section of customers based on Gender, Age group, Ethnicity, etc.</p><h3>Further analysis</h3><p>We may want to define the critical segments, or there could be other subpopulations that need to be inspected for business or compliance reasons.</p><p>We can use atoti to do the subpopulation analysis on the fly, making the whole process much faster and smoother than manually slicing the data to see the metrics for the subpopulations.</p><p>Here is an example of how to create similar subpopulation slicing based on age.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/aa01a0661215d40591200ea3804efa97/href">https://medium.com/media/aa01a0661215d40591200ea3804efa97/href</a></iframe><p>Now we can calculate the evaluation metrics on each of these subpopulations. <strong>Compare this with the effort we need to do such an exercise in pandas and calculating the F1 scores!!</strong></p><h3>Conclusion</h3><p>Before deciding to move a machine learning model into production, make sure to perform a check of the model performance metrics on the subpopulations of interest.</p><p>And<a href="https://www.atoti.io/"> atoti is there</a> to make the subpopulation analysis easy for you.</p><figure><a href="https://www.atoti.io/?utm_source=medium-article&amp;utm_content=technology"><img alt="" src="https://cdn-images-1.medium.com/max/970/1*4VPqJ0BCewWMWZLXmm0F6Q.png" /></a></figure><p>Check out our GitHub repo for the <a href="https://github.com/atoti/atoti/blob/main/03-use-cases/02-other-industries/sub-population-analysis/main.ipynb">notebook with the detailed analysis</a> and other such interesting use cases.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=54d660d4f064" width="1" height="1" alt=""><hr><p><a href="https://medium.com/atoti/why-machine-learning-models-might-fail-in-production-54d660d4f064">Why Machine Learning models might fail in production</a> was originally published in <a href="https://medium.com/atoti">Atoti</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>