As you can see from the screenshot above, the bar chart has a lot of categories but it has no colour difference. You can still see which category comes below or above average, it is still hard to pinpoint. Tableau can improve this view using a simple True/False calculation field.

In the screenshot above, the bars have different colours based on whether they are below or above the average lines.

This post will walk through how you can change the colour of the bars.



Change the Colour of the Bars

The first and most important step is to create a calculated field. This calculated field will contain a formula that specifies the range for below or above based on the average value. One thing to pay attention to here is to write the formula with the right values, especially when you are using LOD expressions. Otherwise, the bars might change colours based on different levels of granularity.


Once the calculated field for colour is created, the next step is to bring it “Color” section of the “Marks” panel.

Lastly, right-click “AGG(Colour)” and go to “Edit Colours,” where you will be able to assign specific colours for average below or above.

It is one of the basic Tableau skills that you can easily apply to your chart. But, it will greatly improve your chart from a visualization perspective. I hope you learned something new, and your dashboard will look more intuitive and effective.


Jeff Hwapyeong Kim
Author: Jeff Hwapyeong Kim

After completing a Bachelor of Theology, I began my Data Analytics journey with the Data School Down Under. I am an analytical, process-oriented, and motivated data analytics consultant with a goal to turn data into information, information into insight, and insight into business decisions. Having a growing interest in the field of data visualization, I always aim to compress complex datasets into approachable and appealing graphics. I have skills in Data Visualization, Data Prep and Manipulation through software such as Tableau, Alteryx, Excel, Power BI, and SQL.