Forum Discussion
Custom name legend
- 10 years ago
Your scenario is still confusing me. Maybe you're looking for something as below?
- Unpivot the table.
- Split the Product column by dot.
- Rename the column properly.
In report window, to avoid confusion, instead of individual pie charts, use one chart with slicer. Create a measure Product Indicator and show it in a Card visual.
Product Indicator = IF(ISFILTERED('Table'[Product]),LASTNONBLANK('Table'[Product],""),"all product")Check more details in a
Z7-852 For pie chart visual under paintbrush icon, you do have option to rename Legend or even turn it off. You can also rename column in your data set.
- Z7-85210 years agoHelper I
Solution given by ankitpatira is not what I'am looking for.
From format you can give a title for legends. This is not what I need.
I need to rename variables without changing their names in the data set. If I chance names in data set I would have to columns both names "Fault A" and I wouldn't know which is for product 1 and which is for product 2.
- ankitpatira10 years agoCommunity ChampionZ7-852
So do you mean changing values of actual rows ? In that case you will have to do replace values via query editor to replace values of actual rows in column which will become legend in pie chart.- Z7-85210 years agoHelper I
ankitpatiraNo I don't want to chance any values.
I have data with columns named "Product1.FaultA", "Product1.FaultB", "Product2.FaultA", "Product2.FaultB" and so on. These variables are binary data (0 = no fault, 1 = fault)
I draw 2 pie charts. In the first I use variables Product1.FaultA and Product1.FaultB. These columns are summed giving me answer how many FaultA and FaultB are in all of the Products1. Same is done for product2.
Now I set legends on. Legends say "Product1.FaultA", "Product1.FaultB" in the first chart and "Product2.FaultA", "Product2.FaultB" because these are the variable names. For reader this is confusing because first chart only contains Product1 faults. So legends shouldn't say Product1.FaultA but only FaultA. If I rename columns I would end up with two FaultA columns (one for product1 and one for product2).
I'am not even sure if this is possible, but for estetic point of view it would be nice.