Forum Discussion
Conditionally Formatting reflects all bars with same colour
- Anonymous3 years ago
Hi Dooriya101 ,
I created a sample pbix file base on your provided data and measures, and I found that the value of measure [Baseline for monthly average number] is same with the ones of measure [Avg Case by PC]. That's why all of bars show the green color. You can try to update the formula of measure [Baseline for monthly average number] as below and check if it can get your expected result...
Baseline for monthly average number = VAR _totalcases = CALCULATE ( [Total Case Number], ALLSELECTED ( 'Case Table' ) ) VAR _totalpc = CALCULATE ( [Total PC], ALLSELECTED ( 'Main Table' ) ) VAR _numofmonth = CALCULATE ( DISTINCTCOUNT ( 'Case Table'[Month] ), ALLSELECTED ( 'Case Table' ) ) RETURN DIVIDE ( DIVIDE ( _totalcases, _totalpc ), _numofmonth )Best Regards
Hi Dooriya101 ,
I created a sample pbix file base on your provided data and measures, and I found that the value of measure [Baseline for monthly average number] is same with the ones of measure [Avg Case by PC]. That's why all of bars show the green color. You can try to update the formula of measure [Baseline for monthly average number] as below and check if it can get your expected result...
Baseline for monthly average number =
VAR _totalcases =
CALCULATE ( [Total Case Number], ALLSELECTED ( 'Case Table' ) )
VAR _totalpc =
CALCULATE ( [Total PC], ALLSELECTED ( 'Main Table' ) )
VAR _numofmonth =
CALCULATE (
DISTINCTCOUNT ( 'Case Table'[Month] ),
ALLSELECTED ( 'Case Table' )
)
RETURN
DIVIDE ( DIVIDE ( _totalcases, _totalpc ), _numofmonth )
Best Regards