<< Back

Tableau 10.2: Legend Per Measure

You can download Tableau 10.2 here

The new version of Tableau, version 10.2, contains various new features that are worth blogging about. One of the new additions to the software is the Legend Per Measure feature. I’ve participated extensively in the beta of the latest release and while I was doing that I created a video in which I demonstrated how easy it is to apply a legend per measure. I’ve added the video in case you missed it.

Tableau Legend per Measure - coming in 10.2

What this new feature entails is that you can now create unique legends for each of the measures you have in your view. From my experience as a consultant I come across this requirement very frequently when I’m at customers. For example, finance departments that deploy Tableau would certainly benefit from this new feature because this makes it easier to colour Profit & Loss tables.

But now you’re probably asking, how do I set this up? Well, let’s use Tableau’s default Superstore dataset. The first step is to build a Measure Values and Measure Names table. For example this one that show Sales, Profit, Discount, Quantity and Profit Ratio per Sub-Category:

The next step is to control (or for macOS cmd) drag your green field called ‘Measure Values’ to the ‘Color’ mark on the Marks Card. Then change the dropdown from text to square in case you want to colour the background of each cell. You’ll see that Tableau just creates one colour legend for your whole table. This has always been the default behaviour, so nothing new here. However, and this is actually the new bit, right click on the Measure Values field that is on Color and click ‘Use Separate Legends’.

There you go! Now you can adjust the colour for each of the measures in the view. This means you can control which of the columns should contain colour. If you for example want a column to be completely white you can set this up by changing the colour palette type to ‘Custom Diverging’. This gives you the option to select a range of colours. This means you can set both the left and right colour to white, don’t forget to change the ‘Step Size’ to 2.

Hopefully this will be help you to get started with Tableau 10.2 and if you have any questions please comment below or ask me on Twitter.

Andre de Vries

London, UK

20 thoughts on “Tableau 10.2: Legend Per Measure

  1. Great – thanks.

    Is there a way to apply different legends to a filtered visualisation (in my case I have a shaded filled map (based on a value) but I’d like the colour scheme to change as the user selects a different dataset to show.


  2. This is great!

    Can we change only one column to circle shape in this new Version?
    Or we need the workaround from previous version?

  3. Andre how did you get the Measure Values to appear in the Marks card twice? I want to accomplish the same thing, but can only place the Measure Values once

    1. Andre, Thanks for the tip!
      I have a question, I want to have a few of my measures retain a white background. When I follow your instructions above, selecting ‘Custom Diverging’ for a continuous measure, I do not have the option of changing my colors, Tableau defaults to a Red & Green diverging. So even if I change the ‘Stepped Color’ option to 2, I do not have a white color.
      Did you do this using a custom color palette?

  4. it is realy good feature, also from performance point of view. Dual axes take much more time when you have a lot of measures. I was kind of struggling with null values. Is it possible to put null values withouth colors. I have Red – Green – White diverting. Red on 90, Green on 110 and center on 100. For null values i am not able to show it withouth color. It is always red with my legend configuration.

  5. This is a great start – just curious – is there a way to colour by the rank of the field (for example) if I have 10 members in my dimension with continuous values for each member – would I be able to color by their Rank (this would be slightly different than coloring by the actual measure). Thanks!

  6. I have a scenario that requires me to create the same set of colors for the table based on a formula but each measure would have the formulas adjusted for different thresholds.
    Measure 1: if > .1, Red, elseif > .8 Amber, END
    Measure 2: if > .2, Red, elseif > .15 Amber, END
    Measure 3: if > .3, Red, elseif > .25 Amber, END

    I don’t think this upgraded functionality would work for this scenario and wanted to use the “placeholder columns” setup that you used in the sped up portion of the video but couldn’t see all of the steps that you did. The advanced conditional formatting video doesn’t follow the exact steps that you used in this video, either. Can you provide the steps that you used in the video?

    1. I am interested in this as well – I am conditional formatting colors based on thresholds/benchmarks that are not the specific measure. I have multiple measures listed (ie, numerator, denominator, rate, benchmark), but only want the rate to be colors, and only based on 25th, 50th, and 75th percentile benchmarks that are not going to be shown.

    2. Same here.

      I have different thresholds for each measure and this solution does not allow me to use calculated fields to define the thresholds.

      If someone finds that out please, advise here.

    3. Obs: The last solution using dual Axis does not work well for me as some measures are being calculated using TabPy, and doing that results im multiple calls being done to Tabpy and making the workbook really slow.

  7. This is great, thanks. I have kpis which change month by month. I’ve followed your instructions, but these seem to work only with a ‘static’ kpi. Is there a way to apply this on differing KPIS within the same measure (ie one measure, across 12 months, koi changes month by month)?

  8. Using 2019.1 version on mac and don’t see the option. Is it in this version or is there a different way to navigate to it? Thanks!

Leave a Reply

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