Tableau is a well-known data visualization tool widely used in the industry and adopted by major firms like Nike, Coca-Cola, Skype, TCS, Accenture, and various other plethoras of companies both large and small. Tableau provides support across platforms such as Azure, Microsoft, Amazon, Redshift, etc making it a household data visualization tool and well accepted in the analytics community. Tableau is easy to use and versatile and anyone without an analytics or BI background can create awesome visualizations with a bit of guidance and practice.
The key away from this article is to build basic charts on tableau but more importantly understand the nuances of the tool. Instead of jumping directly into building a dashboard, the idea is to get familiarized with the tool and its functionality.
Studies show that humans process complex visual data more efficiently than spreadsheets or text tables. For example, using a line graph to track sales trends is an easy and better way than a stack of numbers in a spreadsheet. Identifying outliers, showcasing correlations and tracking progress are some more examples where visual representation is used. For senior management as well as CXO’s having a dashboard is convenient, helps them keep track of the health of the business and visualize different scenarios and identify factors that benefit the business and address pain points so that operations run smoothly, without any roadblock. For associates or analysts, it provides unique business insights, which can be leveraged to build new product features and can be turned into opportunities for growth. Hence the know-how of visualization tools is an important skill to have.
Tableau Desktop – Data visualization tool, which helps to create interactive dashboards and stories. It has a 14 days trial version.
Tableau Server – Helps publish, share, administer tableau desktop content and dashboard.
Tableau Online – On cloud tableau analytics platform. Develop dashboards on tableau desktop and upload to tableau online. Link sharing helps colleagues, customers view the dashboard and make adjustments to the view. The dashboard can be accessed on the web as well as a mobile app. Also can be embedded into a website.
Tableau Reader – It’s a reader tool to view the tableau desktop dashboard without downloaded tableau desktop. It doesn’t have the ability to transform or manipulate dashboards.
Tableau Public – Free platform to transform data into beautiful visualization and share the same online on tableau. Tableau Public has a gallery, where every day a new and interesting visualisation is updated, these can be downloaded along with the data to either recreate the same or explore.
For individual users, the cost of a tableau desktop license as of Sep/2021 is $70/user/month billed annually and for freelancers, this could be a valuable tool for initial EDA/ Model validation – visually showcase independent vs dependant variables or clusters / provide interactive dashboards. The license can be purchased using this link.
Tableau Public is free to use, anyone can download it and work on it, but here’s the catch. All visualization can only be saved on Tableau Public(online website) and not locally. If data security isn’t an issue and learning is the main focus then tableau public very well is the winner.
Tableau hosts viz of the day on their website. A good place to check out real-world dashboards. A good practice is to download and try to recreate the same dashboard.
Download Tableau Public:
Use the link to download tableau public. Once the email id is entered, the download will automatically begin.
Download the superstore dataset :
The most commonly used dataset for tableau exercises and tutorials is the superstore dataset. It can be downloaded from here.
The superstore dataset is retail transaction data or pos(point of sales) data. Retail data has numerous insights and can be used for exercises such as market basket analysis, or customer lifetime value, or churn analysis. The possibilities are infinite. The current dataset has 3 sheets/tables namely Orders, People, Returns. Orders is the main sheet that will be working with. Orders – contains information about the product bought. Below are the columns :
In the free version of tableau, that is tableau public, a total of 11 data connections are available, the most common amount them is Microsoft Excel. The other connections are:
Understanding the tableau workstation and naming conventions will help in not only understanding this guide but also the free tableau video available online.
Data Pane: The data shows all the columns in the data source. The data pane has dimensions which are qualitative and descriptive data for example – Customer name, Segment etc. Measures are quantitative values that can be aggregated using sum/averages etc. Dimensions and measures can be dropped onto the Filter Pane to filter data based on selection.
Fields can be hidden as well, right-click on the field and select HIDE. Fields can be saved to a folder as well – Select the downward-facing triangle beside the search bar on the data pane and select Folder.
Drag and drop fields from the data pane to shelves and cards to create a visualization. Shelves include – marks, filters and pages. Cards include – Columns and rows.
The largest area of the workspace is the view(worksheet), the area where the visualization is visible.
When a field is dropped onto the Columns or Rows it is called a Pill (it’s in the shape of a pill). A blue or green pill. A blue pill is a dimension and the green pill is a measure.
Marks card contains Color, Size, Label, Detail, Tooltip. For all the visualization these tools help to customize the charts. To increase or decrease the bar size, Size can be used. Select edit colors of any chart, select Color and Edit colors. Labels and Tooltip help in creating more informative visualizations by adding text fields or metrics to the visualization.
Let’s create a simple visualization:
Simple Visualization: How to visualize the sum of Discounts across categories.
Creating visualization using the SHOW ME button on the toolbar: Tableau makes it really simple to create visualizations using already existing dimensions and measures through the SHOW ME tool. It has 24 types of charts and under each chart, it shows the numbers of measures and dimensions needed to create that specific chart.
Edit histogram bins size
Select the sub-category dimension and drop it above the category dimension to create a hierarchy. Location hierarchy can be created in the same way, select state, city, region and postal code and drop it onto the country. Hierarchies can be used to drill down into lower levels of data.
A common way to find an aggregate of columns/rows is table calculation. Select Analysis and then select Percentage of to get percentage values or select Total to get total across rows/columns.
Calculated Field to create profit percentage:
To create new variables from existing data, calculated fields can be used. A case when statement can be used to segment based on profit values or percentages. Strings can be trimmed and converted to integers, integers can be aggregated, a calculated field can also be used as a filter.
Practice: Create a calculated field on profit_ratio based on the below code:
Use profit ratio calculated field to segment each transaction into one of the four buckets.
IF [profit_ratio] < 0 then "poor" ELSEIF [profit_ratio] > 0 and [profit_ratio] < 0.3 then "average" ELSEIF [profit_ratio] > 0.3 and [profit_ratio] < 0.6 then "good" else "excellent" END
Tableau parameters help users define values, which then can be processed by a calculated field(can also be used in set, reference line etc). Parameters are sometimes confused as filters, though parameters can act as filters, filters reduce the data points but parameters provide an alternative view and don’t reduce the data points. Defining parameters in itself has no action. They are useful only when combined with calculated fields.
Creating a parameter from a Filter: let’s create a view with Top N customer by sales, with Top N being the user-defined parameter control.
Save the dashboard to tableau public: Tableau desktop provides a variety of options to save a dashboard, most commonly used are twb(tableau workbook file) and twbx(tableau packed workbook), the former is the XML version of the dashboard and is intended for collaboration and doesn’t enclose the data, the latter dashboard is inclusive of data and it’s intended for sharing.
In Tableau public, all dashboards including the data need to be saved in the public domain.
Unlike machine learning algorithms or theory, where memorizing works, tableau needs hands-on practice to be well versed in it. It’s easy to forget everything that’s been written above and one way to make sure nothing is forgotten is to practice what has just been learnt.
Please download the dashboard from this link, and try to develop the same, it’ll take a while but the learnings will be worth it. The dashboard should look somewhat like this …
As an analyst below are the few challenges faced while using tableau:
Tableau certifications are a way to upload and validate tableau expertise. It’s a mix of multiple-choice questions and labs exercises. Currently, there are 6 certifications available :
The fundamental certificate for any data analyst/data scientist or business analyst is a Tableau desktop specialist. It covers the basics of dashboarding and exploratory data analysis using tableau desktop. Strong conceptual knowledge and a few practice sessions using various freely available datasets will be good enough to crack this exam.
Preparation For Tableau Desktop specialist:
Exam Format:
This article is just the beginning of data visualization using tableau. Speed and agility in building dashboards come with practice and the know-how to building dashboards that AWE the audience comes with domain expertise and experience. So practice and always keep learning.
Good luck! Here is my Linkedin profile in case you want to connect with me. Here’s a link to my Tableau Desktop Specialist Certification. I’ll be happy to be connected with you. Check out my other articles on data science and analytics here.
Image 1 : https://public.tableau.com/en-us/s/download
The media shown in this article are not owned by Analytics Vidhya and are used at the Author’s discretion.