Hi All,
I'm having trouble getting conditional formatting to work for a column chart in dashboard studio. I want something pretty simple... I want the column "ImpactLevel" to be colored red if the value is less than 50, orange if the value is between 50 and 80, and yellow if the value is more than 80. Impact level is the only series on the y2 axis of the column chart.
Here is the json for my chart:
Hey @Racer73b !
Found this one pretty frustrating myself. There's lots of prior posts on the topic and I was able to eventually figure it out.
You need to first create unique fields for your value thresholds in your search. See below example:
| makeresults
| eval ImpactLevel="45,55,85"
| makemv delim="," ImpactLevel
| mvexpand ImpactLevel
| eval "Low Impact"=if('ImpactLevel'<50,'ImpactLevel',null())
| eval "Medium Impact"=if('ImpactLevel'>49 AND 'ImpactLevel'<80,'ImpactLevel',null())
| eval "High Impact"=if('ImpactLevel'>79,'ImpactLevel',null())
| fields - ImpactLevel
Then, in your json, make those the fields you want to assign colors to and ensure that stackmode is set to stacked to ignore the nulls.
...