Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Commonly asked question but the answers to this usually use a specific value, not an avg or other funtion...
I have a simple bar chart and I'd like to color some bars a different color, based on some expression in the background color area in the Expression.
I have a bar chart, Services is the dimension and Cases is the expression. In the expression (background color), I use this calculated color, and it works:
=If (Cases > 597, Color (1), Color(2)
But when I try the following, using Avg, it does not work.
=If (Cases>avg(Cases), Color(1), Color(2))
Seems so simple... any ideas are much appreciated. Thank you -
(note that the red reference line is also set to Avg(Cases)
WT
I found the solution:
=If (sum(Cases)>=avg(total(Cases)), Color(1), Color(2))
This produced the desired effect, as if hard coding the value.
I found the solution:
=If (sum(Cases)>=avg(total(Cases)), Color(1), Color(2))
This produced the desired effect, as if hard coding the value.
Yes because i think to compare it reqiures the aggreagate function