Creating a Navigating KPI Block

You know you get those days when your mind just isn’t in the right place?  Well, that was me yesterday – even forgot to collect my daughter from her holiday club… I’d driven home before I remembered – eeek!  She was none the wiser though, as I wasn’t late – phew!

After reading through Ann Jackson’s challenge for Week 30 of #WorkoutWednesday2019 (here), I thought this should be pretty straightforward (Ann had even said so herself), so found it quite perplexing to then be sitting staring at my screen trying to figure out how to get 4 independent measures into a single view in the grid format displayed…..

So I closed my laptop lid, and walked away… well actually went and worked up a sweat in my weekly Zumba class.

After a good physical workout, shower and food, I set about readdressing the mental workout challenge, and promptly had that ‘doh!’ moment…

The focus of the challenge was to utilise some of the new features in Tableau to aid in navigation between dashboards.  Subsequently you’ll need Tableau v2018.3 to be able to complete this challenge.

The solution is built of some very simple views/worksheets, which are then placed on a number of dashboards.  The Go To Sheet dashboard action and Button dashboard object are then utilised to provide the navigation – these are the features introduced in v2018.3.

All relatively straightforward, and I have no idea why I had such a mental block….

My solution consists of 8 worksheets and 5 dashboards, and to build really ended up involving a lot of right-click -> duplicate worksheet. 

1. 4 Block KPI dashboard

This consists of 4 separate views, 1 for each measure. I built the first view (Customers) as follows:

a. Dragged Customer_ID to Text shelf, then changed the aggregation to Count (Distinct) by clicking on the white arrow (carrot) to the right of the pill.

b. Changed the mark type to Square, changed the Size to be as large as possible, and changed the ‘fit type’ to Entire View

c. Edited the text and formatted the size, set the font to ‘match mark colour’ and adjusted the alignment to middle centre

d. Coloured the box, using a recent tip I believe I got from Lorna Eden

If you just select the Colour shelf with the view above, the colour palette below is displayed

Ann mentions in her blog that she uses the Hue Circle colour palette.  The easiest way to access this specific palette is to create a ‘dummy’ pill to put on the Colour shelf.  To do this, simply double click in the space on the marks shelf, below where the text measure is shown, and type the word ‘dummy’ (including quotes) into the area

This creates a new blue (discrete) pill, which you can then add to the Colour shelf, and this will then display the Colour Legend, which you can edit, find the Hue Circle colour palette and select the appropriate colour.

e. Finally edit the tooltips to uncheck the ‘show tooltip’ option.

f. Once done, this sheet can then be duplicated to create the other KPI blocks; you just then need to change the field on the text to be CNTD(Product Name), CNTD(Order ID) or CNTD(City State), where [City State] is a calculated field I created of UPPER([City] + ‘, ‘ + [State]).

g. NOTE – You do need to remove then recreate the ‘dummy’ field on each duplicated sheet though, as otherwise, if you change the colour, it will affect all the sheets.  Simply remove the field, then create a new one by typing directly in the same manner described above.  Whilst you may name this field the same ie ‘dummy’, the removal and recreation actually creates a new instance of the pill ‘under the bonnet’, which is therefore independent of the ‘dummy’ pill on the other sheets, so can be coloured differently.

h. Add these 4 views to a dashboard.

2. Bar chart dashboard

On clicking on each block on the 4 block KPI dashboard, a new dashboard is presented showing a sorted Sales by xxxx bar chart.  Let’s work through creating the Sales By Customer dashboard.

a. Ann likes her UPPERCASE, so first create a calculated field to store UPPER([Customer Name]), and add this to rows and SUM(Sales) to columns and sort.

b. Add both fields to the Label shelf, edit the font sizes to suit, match mark colour and align left middle. Untick ‘show tooltips’ from the Tooltip shelf.

c. Apply formatting to the chart to remove gridlines, columns, rows etc, but keep the axis rulers on rows – make the line thicker/darker to suit.

d. Add a ‘dummy’ pill to set the colour again, and choose the appropriate colour from the hue circle palette again.

e. Untick ‘Show Header’ from the pills on the rows & columns shelf to remove the axis and the Customer column.

f. Change the title to SALES BY CUSTOMER, adjusting the font size & colour to match (you should hopefully see the colour you’ve recently selected out of the hue circle palette in the ‘recently used’ section of the text colour selector

g. Create a new dashboard and add this view to it, and set to ‘fit width’ if it isn’t already

h. Add a floating button object to the dashboard and position top right

i.  Edit button, by clicking the carrot and changing the option

Navigate to – select the name you’ve given the 4 KPI block dashboard

 Button style – Text

Title – GO BACK (and adjust font to suit)

Background – select the relevant colour to match

j. Back to the KPI dashboard, and select Dashboard -> Actions from the menu, and add a ‘Go To Sheet’ action.

Give it a suitable title, then select the source sheet on the KPI dashboard as the one displaying the Customer Count KPI, and set the Target sheet to be the name of the Customers dashboard created above.

Once you’re happy all is working as expected, then repeat the steps outlined above to create a Sales by Product, a Sales By City and a Sales by Order dashboard.  You may need to create some further calculated fields to handle the UPPER case formatting, and don’t forget to recreate the ‘dummy’ field to help with the colouring.

My version of the challenge is published here.

Happy vizzin’



2 thoughts on “Creating a Navigating KPI Block

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s