July 18, 2017

Interactive Reference Lines

Tableau Dashboards provide an incredibly powerful analytic platform. By using a few product features, you can add a very slick interface that displays dynamic text and a reference line on a dashboard. This type of setup works best for trend lines across serveral dimensions. In this example, I am plotting profit ratio across months by Category.

Using Superstore

  • Place MONTH of Order Date to Columns
  • Place Category and Profit Ratio to Rows
  • Enable Text labels and set marks to label to /Highlight/ 
  • From the Color card, choose the second mark type so users can see the label markers more easily
  • Add a reference line to per pane
  • Set the value to Month(Order Date) and aggregation to Minimum
  • Set Label to None
  • The most important setting is to check the box Show recalculated line for highlighted or selected data points

That takes care of the worksheet, now its time to setup a dashboard.

  • Create a dashboard and add the worksheet we just created to it
  • Next we need to add a dashboard action that will enable the dynamic display of the label text and reference line.
  • Add a dashboard action, for Highlight
  • Set the Run Action to Hover
  • Change the Target Highlighting to Selected Fields and check the Month of Order Date.




















That is all, easy right.



Now hover the mouse over and of the line to see the labels appear for each pane and have the reference line appear. This action only works on dashboards and will also display well when published to Tableau Server.

No comments:

Post a Comment