Forum Discussion
Percentage calculation with missing data
- Anonymous2 years ago
Hi AnthNC ,
raji_n said adding the year to the x-axis is one way.
And AnthNC you can also try this, put the field Year into the small multiples:Or you can use this DAX to create a measure:
Measure = IF( NOT ISFILTERED('table1 vehicles'[Year]), IF( MAX('table1 vehicles'[Attribut]) = "Van", "After 2022", BLANK() ), BLANK() )
Place this measure in Data labels > Details:Then the "After 2022" field will appear in the Data label:
I changed the color and font size.
And this will not affect the visual effect after you select the slicer:
Best Regards,
Dino Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Values are appearing correct when I checked the pbix file,
look at the graphs below, the numerator and denominator are dividing properly and the reason why you see van in the bar is because by default the when nothing is selected in the year slicer, all the data is shown.
thank you raji_n
The calculation is correct, this is not a problem.
I am just asking if you guys know a way to show somehow that the 24% corresponding to van drivers (if no years are selected in the slicer) are only representative of the people who were interviewed from 2022 to today...