Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Conditional formatting based on by ID average

Raw data I have:

 

ID | Date | Num
A, Jan-1, 1
A, Jan-2, 2
A, Jan-3, 3
B, Jan-1, 11
B, Jan-2, 22
B, Jan-3, 33
C, Jan-1, 111
C, Jan-2, 222
C, Jan-3, 333

 

 

by ID Avg Measure I created:

 

Avg = var m = FIRSTNONBLANK(Source[ID], "")
return CALCULATE(AVERAGE(Source[Num]), FILTER(ALLSELECTED(Source),m =Source[id]))

 


Matrix visual I want to create but failed - I want to mark those below by ID avg in red, >= in blue.

IDJan-1Jan-2Jan-3by ID Avg
A1232
B11223322
C111222333222

 

Hope it's clear and appreciate your guidance!

3 Replies