1 of 1 people found this helpful
I was unable to open your workbook because I'm not on the latest version, but I'm willing to bet that you have multiple records contributing to each "bar" that is colored on your display.
If a bar represents multiple records, it is using some aggregation calculation (the default is SUM).
In other words, your Color By calculation evaluates on each individual record in your data, NOT at the "aggregate all the records in a given partition and then evaluate."
You can make your "Color By" calculation evaluate in aggregates rather than individual records by changing it to this:
IF SUM([Measles Coverage (Singapore)]) < 30 THEN "RED"
ELSEIF SUM([Measles Coverage (Singapore)]) <= 50 THEN "ORANGE"
ELSEIF SUM([Measles Coverage (Singapore)]) <= 80 THEN "YELLOW"
This will "break" the Color By field if it is being used in any views (the little pill turns red) because this calculation has become an aggregation.
You just need to drag any pill that is red off the view and then drag it back onto the view from the data pane.
It will now show with AGG because the calculation contains an aggregation (SUM) function within its syntax.
Thank you for your insight. I finally manage to get my colour coding right. Much thanks and have a nice day!
Thank you very much, I managed to get it right. Much cheers!