Last modified date: 20 Jul 2023
Environment
Tableau DesktopAnswer
CLICK TO EXPAND SOLUTION
Option 1: Colour each number as over/under a threshold
Note: the video has no sound.
CLICK TO EXPAND SOLUTION
Option 2: Colour each number based on its own value
CLICK TO EXPAND SOLUTION
Option 3: Colour number values based on other discrete fields
CLICK TO EXPAND SOLUTION
Option 4: Colour each column separately
Additional information
Options 1-3 can only colour measure values. Option 4 can colour both measure and dimension values.By design, Tableau Desktop does not apply colour to dimensions. Restricting colour to measures is one way to focus the viewer on the data in the view rather than on the headers. Therefore to colour dimensions in a crosstab, we must place the dimension values in "container" calculated measures.
Colour can be applied either to the text or background of row/column field labels (aka row/column headers) via the formatting options Format Fields and Field Labels. Currently the ability to apply a conditional colour to field labels is not currently built into the product
Notes on Option 3
- [Measure Names] cannot be used in a calculated field, which is why it is necessary to add [Measure Names] to Colour as well as the calculated field to determine colour
- When multiple discrete fields are added to colour on the Marks card, then Tableau Desktop will automatically nest the colours. The first discrete field on Colour is assigned a different colour (blue, orange, green, etc.) and then every value for the next discrete field is given a different shade of those colours. If colours are changed, you can always get back to this default by hitting "Reset" in the Edit Colours dialog.
- The colour legend created may not be very readable. In this case, consider creating a colour legend as in Creating Legends that Apply to Multiple Sheets
- It is not necessary to create multiple "Col" fields, but makes it easier to tell the multiple Marks cards apart because Marks cards are named based on the name of the field.
- To quickly open a particular Marks card, click on the green measure on the Columns shelf, or click on the axis header in the view.
- All measure columns must be the same width.
Thank you for providing your feedback on the effectiveness of the article.
Open new case
Continue searching
Knowledge Base
Community
Product help
Training and tutorials
Related links
Results 1-3 of 52