Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 4.0

...

Loading this into Tableau, we can quickly create a bar chart by double clicking on the Balance measure and then on the Category dimension:

Next, turn this into a running total by clicking the options arrow on the Balance pill, choosing Quick Table Calculation, then Running Total.

We now change the Mark type from Bar to Gantt Bar.  Gantt Bars use two values - one is held on the Rows/Column shelf and marks one end of the Gantt Bar, the second is held on the Size shelf and indicates the length of the bar which then gives us the other end.  In this case we're using the running total as the 'end' value and will deduct the category balance from it in order to draw the line back to the previous value.  (e.g. the running total of Coffee is 30+10 = 40, and the size of the bar will be Coffee's balance, -10.  This draws a Gantt bar from 40 down to 30, lining it up with the total from the previous category).  To deduct the category balance, we create a new calculated field called "Inverted Balance" which has the formula:

...

To change the position of the labels, click the Label shelf, then the Alignment section, and in Vertical alignment, set it to Top:

We can do two things to highlight the direction of change - add colour, and highlight which end of the bar displays the running total.  To add colour, put another copy of the Inverted Balance measure on the Color shelf.  Because we've inverted the number, the default colour scheme will show positive balances as red and negative as green.  Change this by clicking the options arrow on the color legend, and choosing Reversed:

To highlight the running total value, we just need to create a copy of our Running Total formula.  Hold down the Ctrl key and drag the Sum(Balance) pill in the Rows shelf to the right to create a copy of the pill.  Then click the options arrow on the second pill and choose Dual Axis.  This duplicates the value and as they're identical we don't see any difference yet.  Click the options arrow again on the second pill and choose Mark Type -> Gantt Bar.  This will change the Marks shelf so that it includes two mark types which you can switch between using the < and > arrows - the first is our original Gantt bar, the second is our highlight.  Choose the second mark, and remove the Colour and Size measures - this will change the display to a narrow grey line.  Click on the empty Colour shelf and change this to black.  

Download the example waterfall workbook