<?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 Ivan Lubanga  on Medium]]></title>
        <description><![CDATA[Stories by Ivan Lubanga  on Medium]]></description>
        <link>https://medium.com/@ivanlubanga?source=rss-6ca2bc73103a------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*FZ6vIzMSj30H2nzm</url>
            <title>Stories by Ivan Lubanga  on Medium</title>
            <link>https://medium.com/@ivanlubanga?source=rss-6ca2bc73103a------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 20 Nov 2026 14:35:05 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@ivanlubanga/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[Walmart Sales Data Analysis using SQL]]></title>
            <link>https://ivanlubanga.medium.com/walmart-sales-data-analysis-using-sql-5d7c167946b8?source=rss-6ca2bc73103a------2</link>
            <guid isPermaLink="false">https://medium.com/p/5d7c167946b8</guid>
            <dc:creator><![CDATA[Ivan Lubanga ]]></dc:creator>
            <pubDate>Fri, 12 Apr 2024 10:53:36 GMT</pubDate>
            <atom:updated>2024-04-12T10:53:36.318Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/800/1*d0L2lE6AWe9KC9hhi24_GQ.jpeg" /><figcaption>Walmart Store</figcaption></figure><h3>About the Project</h3><p>The project aims to explore Walmart sales data to understand top-performing branches, best-selling products, sales trends of different products, customer behavior and mainly gain insights out of the data to understand different factors that affect sales in the various branches.</p><p>The dataset was obtained from Kaggle <a href="https://www.kaggle.com/c/walmart-recruiting-store-sales-forecasting"><strong>here</strong></a> . The dataset contains sales transactions from a three different branches of Walmart, respectively located in Mandalay, Yangon and Naypyitaw. The data contains 17 columns and 1000 rows.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1ngxwYCSscskyjOfXLAjwQ.png" /><figcaption>Walmart CSV file</figcaption></figure><p>The data required me to carry out 3 main analysis:</p><ol><li><strong>Product Analysis</strong></li></ol><p>Here I conducted an analysis of the find out how various product lines are performing, which products are mostly preferred in relation to gender, the average rating for each product line, best selling product in each branch, product with the largest revenue, product with the largest VAT.</p><p>The product line ranged from electronic accessories, fashion accessories, food and beverage, health and beauty, home and lifestyle, sports and travel.</p><p><strong>2. Sales Analysis</strong></p><p>This analysis aimed to understand the sales trend of various products so as to help the store measure how effective the sales would be and the relevant strategies that the business would apply to increase sales.</p><p>For the Sales analysis I was interested in finding the number of sales made in each time of the day per weekday, the month with the largest cost of goods sold (COGS), the total revenue by month, city with the largest tax percent.</p><p><strong>3. Customer Analysis</strong></p><p>Here I tried to unravel the various customer segments, purchasing trends and the profitability of each customer segment.</p><p>The customers are divided into two categories; <em>members</em> and <em>normal.</em></p><p>I wanted to uncover and get insights on the following about the customers; gender distribution per branch, the customer type that buys most product, gender of the most customers, customer type that bring the most revenue as well as the number of unique customers in the data.</p><p>Approach used:</p><p><strong>Data Wrangling</strong></p><p>This is where I first do my data inspection to detect Null and missing values in my data and replace them.</p><p>I then built a database in MYSQL which I used for the whole analysis.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-sW5R7f9ZZV9vhi_EBCd4w.png" /><figcaption>Database creation \</figcaption></figure><p>After creating the database I then created a table to insert my data which was in the form of a CSV file. since my data did not have any null values I set it as NOT NULL for each field filtering out any null values.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*acBrcg_M1w_0hSkV42tAUg.png" /><figcaption>creating a table in the database</figcaption></figure><p><strong>Feature Engineering</strong></p><p>For this I generated new columns from existing ones which would then help me gather more insights. I added the following columns to my database;</p><ol><li><strong><em>time_of_day</em></strong>; this was to give me insight of sales made in the morning, afternoon and evening and help me answer the question on <em>which part of the day is most sales made.</em></li></ol><p>I used the CASE statement as shown</p><p><strong><em>SELECT<br> time,<br> (CASE<br> WHEN `time` BETWEEN “00:00:00” AND “12:00:00” THEN “Morning”<br> WHEN `time` BETWEEN “12:01:00” AND “16:00:00” THEN “Afternoon”<br> ELSE “Evening”<br> END) AS time_of_day<br>FROM walmart;</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/561/1*a__2ZAcbE5aF8n_pJ6HWDg.png" /><figcaption>adding new column time_of_day</figcaption></figure><p>2. <strong><em>week_day;</em></strong> this contains contains extracted days of the week in which transactions took place and helps answer the question, <em>which day of the week is busiest for every branch.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/446/1*IPF817Akx4xbYkKzAoGSbg.png" /></figure><p>3. <strong><em>month_name</em></strong>; this contains the extracted months of the year when transactions took place and helps to determine the month of the year with most sales and profits.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/446/1*2WgiHUwR5ogIgWnA1vcwNw.png" /></figure><p><strong>Exploratory Data Analysis (EDA)</strong></p><p>This is done to answer the business questions and aims of the project based on the 3 main analysis; Product, Customer and Sales as earlier mentioned.</p><p><strong>Product Analysis</strong></p><p>In this analysis we answered the following questions;</p><ol><li><strong><em>How many unique product lines does the data have?</em></strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/506/1*dX6l8CihRzFKBT3yNAl3og.png" /></figure><p>2. <strong><em>What is the most common payment method</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/503/1*CKLXNi4m1knv1KFohrt-VA.png" /></figure><p><strong><em>3. what is the most selling product line</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/499/1*6BEz0m2Iz6LQlRYrdVviJw.png" /></figure><p>4. <strong><em>What is the total revenue by month?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/432/1*ehr448oJDGo5cDAZoGCPYA.png" /></figure><p><strong><em>5. What month had the largest COGS?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/328/1*M0TVVieVRhrwW4tC5XbCYw.png" /></figure><p><strong><em>6. What product line had the largest revenue?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/410/1*wWTSksbRkGbPR9G3o2-iZw.png" /></figure><p><strong><em>7. What is the city with the largest revenue?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/443/1*udCYbQeGSQRvSFSCQzBUHg.png" /></figure><p><strong><em>8. What product line had the largest VAT?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/408/1*8LcmEHaqYErWIHNlMSS-9A.png" /></figure><p><strong><em>9. What is the most common product line by gender?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/492/1*yTd5M2GWhRetZnevDg8I3w.png" /></figure><p><strong><em>10. Which branch sold more products than average product sold?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/581/1*V6d9KoB_6wGjTM6fKv0_JQ.png" /></figure><p><strong><em>11. What is the average rating of each product line?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/488/1*dAQa3exw0Sqmrcmt2v0psA.png" /></figure><p><strong>Product Insights</strong></p><p>i) Most customers preferred using cash as a method of payment than e-wallet and credit card.</p><p>ii) The most selling product line is fashion accessories while the least is health and beauty.</p><p>iii) January had the highest revenue of 116291 followed by March at 108867 and lastly February at 95727.</p><p>iv) Food and beverages had the largest revenue at 56144 while Health and beauty had the lowest of 48854.</p><p>v) The most common product line by gender was Fashion and accessories which was highly preferred by females at 96. Males preferred Health and beauty products at 88 which was however least preferred by females at 63.</p><p>vi) Food and beverage had the highest rating of 7.1 by the customers while home and lifestyle products had the least rating of 6.83.</p><p><strong>Sales / Customer Analysis</strong></p><ol><li><strong><em>Number of sales made in each time of the day per weekday</em></strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/524/1*2Hyg8nvp2ZDHFxJgAlj8dA.png" /><figcaption>Sales made on Monday</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/605/1*zR_YuUTRzj9kxEZpPcQaNQ.png" /><figcaption>Tuesday Sales</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/551/1*b2AL1XwcM6V3pYdctex7Iw.png" /><figcaption>Wednesday Sales</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/574/1*B6XCZB2nBknMTd_VerR4SQ.png" /><figcaption>Thursday Sales</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/588/1*mjheKuaH7-y3NFAXdT5QDg.png" /><figcaption>Friday Sales</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/629/1*Ruzy6ki3PBH2gmJXG535cg.png" /><figcaption>Saturday Sales</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/575/1*s7MTfOv5pYnGKAPMWDohKA.png" /><figcaption>Sunday Sales</figcaption></figure><p>2.<strong><em> Which of the customer types brings the most revenue?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/500/1*EZKkx0TdAD6VTXs_DgfXWA.png" /></figure><p>3. <strong><em>Which customer type pays the most in VAT?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/403/1*yFyFSvmWAzvoY9sm8pZzdg.png" /></figure><p>4. <strong><em>What is the most common customer type?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/439/1*T6pqCw23j6D1jPqS6w9EZg.png" /></figure><p><strong><em>5. What is the gender of most of the customers?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/439/1*Qriooi11EsbS_I9ai19OYA.png" /></figure><p><strong><em>6. What is the gender distribution per branch?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/463/1*Tv9kG4fDtUuGZMNxiQ-aOg.png" /><figcaption>Gender Distribution in Branch B</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/435/1*VUzZ_tLqR0Y8wfbr6ivfZg.png" /><figcaption>Gender Distribution in Branch A</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/451/1*FUDMi4ttiL22yrV0rslJvA.png" /><figcaption>Gender Distribution in Branch C</figcaption></figure><p><strong><em>7. Which day of the week has the best average ratings?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/466/1*b2pvuFPOdzoqHVZXZ6vR7g.png" /></figure><p><strong><em>8. Which day of the week has the best average ratings per branch?</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/610/1*xLbYCnwM2ExS6cOzs6DktQ.png" /><figcaption>Average rating for Branch A</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/564/1*wiveCC5Kw0gbKFsLsrC35Q.png" /><figcaption>Average rating for Branch B</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/593/1*F5vnfjditohcA5vdHE16Jg.png" /><figcaption>Average rating for Branch C</figcaption></figure><p><strong><em>9. Which product line is popular between the two customer type</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/568/1*Wh3Lz7VwwZkQTtGA2fzidA.png" /></figure><p><strong>Sales and Customer Insights</strong></p><p>i) The most common customer type are the Member customer who are 499 in number; the Normal customers are 496 in number.</p><p>ii) Evenings had the highest number of sales. This implies that most people do their shopping around that time as compared to morning and afternoon hours. Also Saturday had the highest number of sales while Monday had the least sales.</p><p>iii) The Member customers bring the most revenue at $ 163625 while the Normal customers have a revenue of $157261.</p><p>iv) Member customers pay the highest VAT of 15.61% while the normal customers pay a VAT of 15.1%</p><p>v) In terms of gender distribution the number of male customers are 498 while Females are 497.</p><p>vi) Monday has the best average ratings of 7.13 while Wednesday was the least rated with 6.76.</p><p>vii) The most common product line among the Member customers is Food and Beverage while for the Normal customers, Fashion Accessories was the most popular.</p><p>In summary, the analysis is meant to give insights to this business on the sales revenue generated daily, weekly, and monthly as well us get to understand the customers’ behavior and preferences on different product lines.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5d7c167946b8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[UK Road Accident dashboard]]></title>
            <link>https://ivanlubanga.medium.com/uk-road-accident-dashboard-a7c1be214628?source=rss-6ca2bc73103a------2</link>
            <guid isPermaLink="false">https://medium.com/p/a7c1be214628</guid>
            <dc:creator><![CDATA[Ivan Lubanga ]]></dc:creator>
            <pubDate>Wed, 02 Aug 2023 14:48:44 GMT</pubDate>
            <atom:updated>2023-08-02T15:21:12.436Z</atom:updated>
            <content:encoded><![CDATA[<p>Hello everyone, welcome to yet another walkthrough of my Excel interactive dashboard which gives insights about road accidents in the United Kingdom.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yQTY5yVYeRQzRGPfTXjv_Q.png" /><figcaption>Road Accident Excel dashboard</figcaption></figure><p>Using Manipulated Data (not official data) found <a href="https://en.wikipedia.org/wiki/Reported_Road_Casualties_Great_Britain"><strong>here</strong></a> my process for coming up with this dashboard involved the following processes:</p><ol><li><strong>Data cleaning</strong></li><li><strong>Data processing — which involves using formulas and building customized columns.</strong></li><li><strong>Data Analysis — involving the use of aggregation data</strong></li><li><strong>Data Visualization</strong></li><li><strong>Reporting/ Creating a dashboard</strong></li></ol><h4>Requirements</h4><p>The client/ stakeholders wish to have a Road Accident Dashboard for the years 2021 and 2022 so that they can have insights on the below requirements:</p><p><strong>Primary KPIs</strong></p><p>—<strong><em> to show Total Casualties after the accident.</em></strong></p><p><strong><em>— to show the total % of casualties with respect to accident severity and max casualties by vehicle type.</em></strong></p><p><strong>Secondary KPIs</strong></p><ul><li><strong><em>To show casualties with vehicle type.</em></strong></li><li><strong><em>Monthly trend showing the comparison of casualties for the current and previous year.</em></strong></li><li><strong><em>Maximum casualties by road type.</em></strong></li><li><strong><em>Distribution of total casualties by road surface.</em></strong></li><li><strong><em>Relationship between casualties by area/location and by day/night.</em></strong></li></ul><p>I also had to identify some of the stakeholders whom the data would be relevant for and they included:</p><ul><li><strong><em>Ministry of Transport</em></strong></li><li><strong><em>Road Transport department</em></strong></li><li><strong><em>Police force</em></strong></li><li><strong><em>Emergency Service Department</em></strong></li><li><strong><em>Road safety corps</em></strong></li><li><strong><em>Transport operators</em></strong></li><li><strong><em>Public</em></strong></li><li><strong><em>Media</em></strong></li></ul><p>My data was MetaData within a file extension of xlsx with 3.07 million rows as well as 21 fields.</p><h4>Data Cleaning</h4><p>Here I started by organizing the cell size, adjusting columns to ease the view of data, adding filters, check on any missing or misspelled values using the filter columns as well as replacing values.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XR8SaygfcNE7RnskVUgt_g.png" /></figure><h4>Data Processing</h4><p>Based on the requirement I was supposed to show a trendline between the current year and the previous year’s casualties.</p><p>The trendline shows in months which required me to add a monthly column.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RRYRjrMp4VWAn3TU2VSojg.png" /></figure><h4>Data Analysis and Data Visualization</h4><p>Here is where I created charts and visuals using pivot tables.</p><p>I started by working on creating the Primary KPIs</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oz7CwfJdkOVMtfC-yqOysw.png" /><figcaption>Determining the % of fatalities</figcaption></figure><p>Next, I created the doughnut charts for the primary KPIs</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZKckQN80JuK34hJZyyIUkQ.png" /><figcaption>Primary KPI charts</figcaption></figure><p>I went on to add the KPIs on my dashboard but first I had to create shapes for my KPIs as shown below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*d3-K1lkaDUqGhnE1E_TRog.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*E1uSnCBEqwT_GT-z8DNtMA.png" /></figure><p>I went ahead to create the 4th KPI for my dashboard which I named Casualties by Car since car accidents had the largest number of casualties.</p><p>I decided to group car and Taxi/private hire car into one using calculated items using the syntax</p><p><strong><em>Select Car&gt; Analyze tab&gt; field item sets&gt; calculated item&gt; Name (cars)&gt; formula (= Car + Taxi)&gt; Add</em></strong></p><p>I did the same for <strong><em>Bus/coach and Minibus</em></strong> as well as <strong><em>Goods vehicles and Vans </em></strong>and also for<strong><em> other vehicles, pedal cycles, and ridden horses </em></strong>which I renamed as <strong>others </strong>as demonstrated below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mG0OSp0UjqxCEL3f5O1rxQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0ALokxpaLsm-YTqnrxU3Fw.png" /></figure><p>My next step was to add Secondary KPIs which included adding images of vehicle types that I downloaded from the internet as well as adding more shapes for the other KPIs.</p><p>I then went ahead to prepare a monthly trend for the current year and the previous year by creating another pivot table where I had months in Rows, Year Filters, and the Number of Casualties to Values; after which I filtered the year to 2021, pasted the pivot and filtered for 2022.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*52g9KpDRhxDmjzPuIxqZ6A.png" /><figcaption>Monthly Trend pivot table</figcaption></figure><p>Next I created a Combo chart by extracting the values outside the pivot table starting by month and selecting the entire table and inserting a 2D chart, a bar chart to represent casualties by road type and a Tree Map to show Casualties by Road Surface.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cGQaOFoZH_lW9CFP5RkmJg.jpeg" /></figure><p>I then added a filter panel in form of slicers and connected it to the rest of the dashboard by <strong>Report Connection. </strong>The timeline was linked to all the other visuals except the monthly trend.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1018/1*f5adS88a2nxZBaHPpyj3fQ.jpeg" /><figcaption>Filter panel for accident date and location</figcaption></figure><p>Finally, it was time to work on the side panel which redirects the stakeholders during their navigation on the dashboard.</p><p>I created icons for the same such as dashboard, data, Gmail in casethe stakeholders needed to share the dashboard with others, and URL link to direct the stakeholders to where the information about the accidents could be found on the internet.</p><p>For the data icon, I had to create another sheet which I named Data Analysis. This will show the various analysis done during the whole project.</p><p>I inserted a hyperlink to the data icon in order to direct the stakeholder to the Data analysis sheet.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*36abWGKl_a9aUXO38VF9og.png" /><figcaption>Inserting hyperlinks to the panel icons</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WaAUpJAxPFqKWnBCo_Fy5A.png" /><figcaption>Data Analysis sheet</figcaption></figure><p>Finally we have the final dashboard which is very interactive</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yQTY5yVYeRQzRGPfTXjv_Q.png" /><figcaption>Final Dashboard</figcaption></figure><p><a href="https://drive.google.com/file/d/1OMURitewGWaER3CrFGth27hsK0qVyPKO/view?usp=drive_link">Google Drive: Sign-in</a></p><p>The abovelink is a 1-minute video showing how the dashboard works.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a7c1be214628" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Heart Failure Tableau dashboard Project]]></title>
            <link>https://ivanlubanga.medium.com/heart-failure-tableau-dashboard-project-80784ddfa559?source=rss-6ca2bc73103a------2</link>
            <guid isPermaLink="false">https://medium.com/p/80784ddfa559</guid>
            <dc:creator><![CDATA[Ivan Lubanga ]]></dc:creator>
            <pubDate>Thu, 13 Jul 2023 18:26:42 GMT</pubDate>
            <atom:updated>2023-07-13T18:29:20.408Z</atom:updated>
            <content:encoded><![CDATA[<h3>Heart Failure in the United States Tableau dashboard Project</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*3JfeHLbJjhoA2QYW" /><figcaption>Photo by Towfiqu barbhuiya on Unsplash</figcaption></figure><p>I have been recently working on a heart failure data From the National Heart, Lung and Blood Institute in the United States of America which you can learn more about on this link <a href="https://www.nhlbi.nih.gov/health/heart-failure">https://www.nhlbi.nih.gov/health/heart-failure</a> to identify some of the most common causes of heart failure in relation to age and sex.</p><p>My data set which can be found here <a href="https://www.kaggle.com/datasets/andrewmvd/heart-failure-clinical-data">https://www.kaggle.com/datasets/andrewmvd/heart-failure-clinical-data</a> consisted of 12 features (5 categorical and 7 continuous variables). The target which is Death is binary ie:</p><p>0 for survival</p><p>1 for death</p><p>For categorical variables I had:</p><ul><li>Anemia where 0= negative, 1= positive</li><li>Diabetes</li><li>High blood pressure</li><li>Sex where 1= male, 0= female</li><li>Smoking where 0= non smoker, 1= smoker</li></ul><p>I used Aliases in Tableau to replace the values.</p><p>For the continuous variables I had:</p><ul><li>Age</li><li>Creatinine phosphokinase</li><li>Eject fraction</li><li>Platelets</li><li>Serum creatinine</li><li>Serum sodium</li><li>Time</li></ul><p>First I converted all the categorical variables into dimensions.</p><p>The syntax looked like:</p><blockquote>Death event&gt;select Aliases where 0= survived, 1= death</blockquote><p>I started with creating a doughnut charts</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*neiQ5aLIhbRPjYuymmoSzg.png" /><figcaption>Doughnut chart</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ojDj50vJ9P1yxNLq3zXERw.png" /><figcaption>Doughnut chart showing survival status of various diseases associated with heart failure</figcaption></figure><p>Then I created Histograms for some of the categorical and continuous variables</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7w4SBcc3304nd5_bmcVRFQ.png" /><figcaption>Histogram showing survival status by age</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZzlonK-kDZP_YPxjua5lvA.png" /><figcaption>Histogram showing survival status by Time</figcaption></figure><p>Next I created a scatter plot showing the for age, time and survival status</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*aiwTf8TCUiEUUTYEiQ9z0w.png" /><figcaption>Scatter plot showing survival status with respect to age and time</figcaption></figure><p>I went ahead to create a box plot showing the relationship between age, sex and survival status</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HNRrHLsnCu0T79fa5eHhOQ.png" /><figcaption>Box plot showing survival status with respect to age and sex</figcaption></figure><p>Finally I created the KPI’s for Total Individuals, Total Deaths, Total males and females respectively.</p><p>This I created calculated fields and a syntax for this looked like:</p><blockquote>Total Individuals&gt; drag into text&gt; hide title&gt; drag death event into text&gt; select count on death event&gt; increase width for visibility&gt; format&gt; shading&gt; black</blockquote><blockquote>Font&gt; bold&gt;11</blockquote><p>The final Dashboard which I gave a width of 1900 and height of 1050 looked like this</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HFvUyXgkhrKf3fn5TFHaGw.jpeg" /><figcaption>Dashboard for Heart Failure Survival status</figcaption></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=80784ddfa559" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>