I have a stacked bar chart where one category will always have a 0 value. The category name is also null in this case. Although there is no value so the items don’t show up in the stacked bar chart, the Unknown category does show up in the legend. I cannot suppress the nulls because I do want to include the null category counts in another part of the visualization.
Is there another way to remove or hide the Unknown category from the legend?
Hiding zero or (unknown) value from chart legend
You can hide the unknown category on the legend by unchecking the ‘Retrieve Unknown Members’ on the hierarchy configuration from the data analysis panel.
For example, I have a visualization with a 0 value and an unknown category name.
Then, I re-visualize the table into a stacked bar with a legend.
To remove the unknown category, I click the pencil icon on the category hierarchy and uncheck the ‘Retrieve Unknown Members’
Hope this helps.
Best regards
Thanks for the response. I don’t believe this will work in my case because I do actually want to retrieve the unknown values.
In addition to the bars showing the categories, i also have a line showing an overall rate which means the nulls are part of my denominator.
My very clunky resolution was to create two charts, stacked on top of each other, with slightly different metric sets. However, this happens to me pretty often and the solution isn’t ideal since alignment can be an issue with resizing, data changes, etc.
You can achieve this by adding a space to the ‘Unknown Member Caption’ field on the hierarchy to make it empty and editing the chart palette of the ‘Unknown’ category name to white on the property panel.
For instance, I have a chart with an unknown item.
On the data analysis panel, I click the pencil icon on the hierarchy and add a space to the ‘Unknown Member Caption’.
The unknown item appears as blank on the Legend.
On the property panel, select the data point series and in the look section select the ‘Chart Palette & Color Rules’ to edit color assigned to the unknown item.
The unknown item is no longer visible on the chart.
Hope this helps.
Best regards