Today we are going through the entire process of creating a Likert Scale Diverging Bar in Tableau. This chart type is a very useful and beautiful visualisation because it shows a rating ordered in sequences, and the marks are orientated in opposite directions: positive/negative values, right/left. This means that it is easier to observe the differences between values and also to compare them.
The history of the Likert Scale is interesting because the first one was created by the psychologist Rensis Likert, who needed to represent ratings regarding international affairs. A type of Likert scale is also the one you have to give a rating from 1 to 5 (for example), 1 representing that you strongly disagree, and 5 that you strongly agree.
Tableau offers the possibility of creating a unique Likert Scale Diverging bar. In this #skillpill video, we will show you an example of analysing the profit ratio for the furniture, office supplies and technology from a database from the United States.
Here is the video tutorial:
… and here are the written steps:
→ In Tableau Desktop, connect to Superstore dataset from Tableau.
→ Create a calculated field called Number of Records – where the formula is: ‘1’.
→ Create a calculated field called Total Count – where the formula is Total(Sum[(Numbers of Records])).
→ Create a calculated field called Profit Ratio – where the formula is SUM([Profit])/SUM([Sales]).
→ Create a calculated field called Profit Ratio by Order – where the formula is ([Profit])/([Sales]).
→ Create a calculated field called Profit Ratio Type – where the formula is IF [Profit Ratio by order]<0 then ‘Negative’ ELSEIF [Profit Ratio by order]<0.1 then ‘Neutral’ else ‘Positive’ END
→ Create a calculated field called Count Negative – where the formula is IF [Profit Ratio by order]<=0 THEN 1 else if [Profit Ratio by order]<=0.1 then 0.5 ELSE 0 END
→ Create a calculated field called Total Count Negative – where the formula is TOTAL(SUM([Count Negative]))
→ Create a calculated field called Gantt Start – where the formula is -[Total Count Negative]/[Total Count]
→ Create a calculated field called Percentage – where the formula is SUM([Number of Records])/[Total Count]
→ Create a calculated field called Gantt Percent – where the formula is PREVIOUS_VALUE([Gantt Start])+ZN(LOOKUP([Percentage],-1))
→ Create a parameter called Show Percentages with the data type string and a list with the following values: Show Percentages and Show Profit Ratio
→ Create a calculated field called Show Profit Ratio – where formula is IF [Show Percentages]=’ Show Profit Ratio’ then [Profit Ratio] END
→ Create a calculated field called Show Percentage – where the formula is IF [Show Percentages]=’ Show Percentages’ then [Percentage] END
→ Create a hierarchy Country, Category si Subcategory – Bring Category over Country and Subcategory below Category.
→ Bring the Hierarchy created earlier on rows.
→ Bring Gant Percent and Show Profit Ratioon on columns.
→ For Gant Percent, bring Profit Ratio Type on colour, Percentage on size and Show Percentage on the label.
→ For Gantt Percent, we are going to select Gantt Bar.
→ For Show Profit Ratio, we are going to select Circle.
→ Bring the parameter Show Percentages –right-click and select– Show parameter.
→ Select right click – axis and select Dual Axis and Synchronize Axis.
→ Format Show Percentages and Show Profit Ratio on the labels to appear as a percentage – right-click – format – number – Percentage.
Author: Alina Pătulea, Data Analyst @btProvider
We hold all possible technical and sales certifications for all products: Tableau Desktop, Tableau Public, Tableau Server, Tableau Prep, Tableau Data Management.
With Tableau Software – the best data visualization platform – you can always understand your business or your job better. Using Tableau, you will take smart and strategic decisions and you will quickly understand the data flow, numbers and results it produces.
Are you interested in learning more about Tableau Software – one of the best analytics tools and implementing the solution in the entire company? Contact us!
See how Tableau works, by downloading a free trial here:
In this Skillpill, you will learn how to create a Parliament Chart in Tableau. A Parliament Chart, or semicircular chart, represents the distribution of parliamentary seats. It is not a standard chart type in Tableau but can be manually created […]
What is a Context? Contexts are used to configure a Job for standard environments within the Software Development Life Cycle, such as Development, Testing, and Production. A Job always runs within a specific context. When a context is selected in […]
In Talend Cloud Management Console (TMC), you can create executable tasks and execution plans, which can be run directly in the Cloud or with a Remote Engine. You need to create an execution plan to allow automated runs in TMC, […]