Forum Discussion
Tableau to power BI Color coding
- 4 years ago
Anonymous , to understand attr, need some sample data. As of now assumed you have measures for Min and Max days
Create a new measure and use that in conditional formatting using filed value option
Switch( true() ,
SUM([True Audit Days]) < ([MIN DAYS]) , "red" ,
SUM([True Days]) > ([MAX DAYS]) ,"red" ,
"green"
)refer if needed
Tableau ATTR: https://www.youtube.com/watch?v=6mXMPX7S8oU&list=PLPaNVDMhUXGYzjFASXjdY7GNoFxvlkR54&index=21
How to do conditional formatting by measure and apply it on pie?: https://youtu.be/RqBb5eBf_I4
Hi, Anonymous
Create a measure like:
ColorMeasure = SWITCH(TRUE(),
SUM([True Audit Days]) <ATTR([MIN DAYS]), 1, --see remarks below
SUM([True Days]) >ATTR([MAX DAYS]), 1,
2)
not sure what ATTR is doing, but you can replace by SELECTEDVALUE ... SELECTEDVALUE('Table'[SomeColumn],"*")
Then go to condition formatting and if is background for example, use by Rule and search for this measure. Rules will be:
If = 1, select some red color,
If = 2, select some green color
Did I answer your question? Please Like and Mark my post as a solution if it solves your issue. Thanks.
Appreciate your Kudos !!!