Forum Discussion
Issue with measure
- 7 months ago
Hi christinas ,
Your google search are correct you need in fact a new calculation in order to get it to properly do the condittional formating because in Power BI the conditional formatting can be done in 3 different manners (gradient, rules and calculation) but all of them are always around a single value is not for example has in excel where you can add a calculations (ex: A1 >= B1).
However if this is a single use case and you only want to have that comparision in this specific visual, so no reusage of the formatting you can do that calculation using Visual Calculations.
https://learn.microsoft.com/en-us/power-bi/transform-model/desktop-visual-calculations-overview
Then on the conditional formatting you can use that calculation to do the formatting.
Steps Below:
1. Create the visual calculation
2. Add the formula:
Difference to median = [Average Salary] - [Market Median]Call it whateve you find more appropiated
3. Do the condittional formatting on top of the difference
Final result
Hi christinas ,
Your google search are correct you need in fact a new calculation in order to get it to properly do the condittional formating because in Power BI the conditional formatting can be done in 3 different manners (gradient, rules and calculation) but all of them are always around a single value is not for example has in excel where you can add a calculations (ex: A1 >= B1).
However if this is a single use case and you only want to have that comparision in this specific visual, so no reusage of the formatting you can do that calculation using Visual Calculations.
https://learn.microsoft.com/en-us/power-bi/transform-model/desktop-visual-calculations-overview
Then on the conditional formatting you can use that calculation to do the formatting.
Steps Below:
1. Create the visual calculation
2. Add the formula:
Difference to median = [Average Salary] - [Market Median]
Call it whateve you find more appropiated
3. Do the condittional formatting on top of the difference
Final result
Hi MFelix . Thank you for your response. I will try it out.