Here's a good 'un, using a parameter to highlight. I know, create a bar chart, make a parameter, use a boolean output, stuff the pill onto the colour marks, and watch as each of your selected attributes instantly flashes up your chosen highlight colour |
That wasn't so hard was it?
Now make a tree-map:
But, oh dear, each time you select an item, Tableau moves the item out of sequence. Sure, it is being highlighted, but the sequence is not retained, why?
Well, this is all down to how your marks are laid-out. You see, when using the rows and columns, Tableau is able to use these to define the primary output, so bars and lines already have a pre-defined structure, any further attributes placed on the marks card, calculated or otherwise are only secondary to the layout.
But, when the rows and columns are not used, the marks card becomes Tableau's only source for determining layout, so all dimensions are used in the layout, with Tableau then splitting the final underlying table to include those items inside the boolean filter, and those that are out. So in the case of the hierarchical map, a further dimension has been added: Category, Sub-Category and boolean filter.
So how do we get around this?
By using a boolean output that Tableau will not use as part of the layout, by using a calculated measure:
Min(Iif([Sub Category] = p_SubCat,-1,1)) |
Create a step-by-step guide:
The content by label feature displays related articles automatically, based on labels you choose. To edit options for this feature, select the placeholder below and tap the pencil icon.
|