LOADING

Type to search

Tableau KPI Next to Bars

To Know more about the Different Corporate Training & Consulting Visit our website www.Instrovate.com Or Email : info@instrovate.com or WhatsApp / Call at +91 74289 52788

Data Analytics Tableau

Tableau KPI Next to Bars

Share

If you would have happened to read my earlier Blogs you would have noticed that I have kept saying that Tableau is all about visualizations and that too visualizations that will make you stand apart. That means, you add little enhancers in your visualization that will make it appear different from a normally created viz; along with that it should satisfy your 80 : 20 relation(that means, in first 20 sec at the look of your viz you should come to know 80% of what your analysis is.).

So, on this ground, let’s make another viz that we will prove that we have an expertise in Tableau and we can actual make a viz that would be little different from others.

This time let’s change our dataset so that you can practice all the various examples that I have shared with you earlier on this data set also and gain some extra hands on experience. So, for this example we will use Sample Superstore Sales (excel) and in case you do not have the data set you can download it from the below link:

https://community.tableau.com/docs/DOC-1236

Step- 1: Open Tableau and connect it to Sample Superstore Sales (excel).

Tableau will ask you to use a Data interpreter, but you can skip using it. Drag Orders table to the Data source preview space.

Tableau KPI Next to Bars 29

Step-2: Drag Order Date (Dimension) and Customer Segment (Dimension) to the Worksheet.

Tableau KPI Next to Bars 30Tableau KPI Next to Bars 31

Step- 3: Make two Calculated Field:

  • Latest Year with the formula:

 IF {MAX(YEAR([Order Date]))} = YEAR([Order Date])

THEN [Sales] ELSE 0 END

Tableau KPI Next to Bars 32

  • Prior Year with the formula:

IF {MAX(YEAR([Order Date]))} – 1 = YEAR([Order Date])

THEN [Sales] ELSE 0 END

Tableau KPI Next to Bars 33

Bring these two Calculated field to the Viz and using your Show me button make a proper Text Table like the below:

Tableau KPI Next to Bars 34

Step- 4: Prepare a Bar Chart with Customer Segment in Rows and Latest Year in the Columns of the worksheet.

Tableau KPI Next to Bars 35Tableau KPI Next to Bars 36Tableau KPI Next to Bars 37

Step- 5: Put Prior Year Calculated field in Detail Shelf in the Worksheet and from the Analytics Pane add a reference line of Prior Year on per Cell.

Tableau KPI Next to Bars 38

Step-6:  Now we want to put the KPI next to the bars. For this we make 2 Calculated fields:

  • YoY Growth with the formula:

SUM([Latest Year]) >= SUM([Prior Year ])

Tableau KPI Next to Bars 39

  • Mark Position with the formula:

AVG(-50000)

Tableau KPI Next to Bars 40

Step- 7: Put Mark Position to Column & Dual Axis n synchronize axis.

Go to Latest Year marks card and switch it to bar. Then go to Mark Position and bring out Shape. Add YoY growth to shape & put desired shape.

Tableau KPI Next to Bars 41

Leave a Comment

Your email address will not be published. Required fields are marked *