Forum Discussion
Anonymous
4 years agoNot applicable
Coloring Values Assistance
Hello community! I have created a matrix and a table on the same tab of a Power BI Report. (See 1st picture below) The table on the left uses conditional columns which I manually inserted int...
- 4 years ago
Anonymous,
You can achieve this with a measure that determines the color:
Color Measure = VAR vCount = [Count StudentID] VAR v15Staff = MAX ( Table1[15 Staff] ) VAR v5Staff = MAX ( Table1[5 Staff] ) VAR vResult = // use color names or hex codes SWITCH ( TRUE, vCount > v5Staff, "Green", vCount < v15Staff, "#E6113C", "Yellow" ) RETURN vResultCreate conditional formatting for the measure [Count StudentID]:
- 4 years ago
Hi, Anonymous
Based on the data you have provided, you can refer to the following methods.
Measure = Var N1=DISTINCTCOUNT('Table'[StudentID]) return SWITCH(TRUE(), N1>SELECTEDVALUE('Table'[5 Staff]),"Green", N1<SELECTEDVALUE('Table'[15 Staff]),"Red", "Yellow")Is this the result you expect?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
v-zhangti
4 years agoCommunity Support
Hi, Anonymous
Based on the data you have provided, you can refer to the following methods.
Measure =
Var N1=DISTINCTCOUNT('Table'[StudentID])
return
SWITCH(TRUE(),
N1>SELECTEDVALUE('Table'[5 Staff]),"Green",
N1<SELECTEDVALUE('Table'[15 Staff]),"Red",
"Yellow")
Is this the result you expect?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.