Tableau Butterfly Chart

Tableau Butterfly Chart is the combination of two bar plots on either side of the same y-axis. Typically, Butterfly Chart helps to compare two data sets at a time. In this article, we use the superstore excel file to build this. 

Create a Butterfly Chart in Tableau

Drag and drop the Sub-Category dimension to the row shelf.

Drop Dimension Field to Rows Shelf 1

Next, drop the Sales measure into the column shelf multiple times. By default, it displays two horizontal bar plots side-by-side.

Tableau Butterfly Chart 2

For this tableau butterfly chart, right-click on the dimension section to create a calculated field. Next, select the Create Calculated Field.. option from the context menu.

Tableau Butterfly Chart 3

We named the calculated field as Zero and placed 0, which means it shows zeros.

Zero calculated Field 4

Drag the Zero calculated field onto the columns section in-between the two sales fields. As you see, we have Sales, Zero, Sales, Zero on the columns shelf, and Sub-Category on the Rows shelf.

Tableau Butterfly Chart 5

Convert the Circles of Zero field to Bars using Marks shelf.

Tableau Butterfly Chart 6

Next, we are converting the remaining column measure fields to bar charts by changing Marks.

Tableau Butterfly Chart 7

Now, you can see the Bar graphs. We have to convert this to Tableau Butterfly Chart.

Tableau Butterfly Chart 8

Let me change the Zero field to Tableau Text or labels.

Change the Text 9

As its value is 0, it shows Abc as the text.

Tableau Butterfly Chart 10

Select and right-click on the Sales field, zero fields, and select Synchronize Axis option.

Synchronize Axis

Now the data of both the measures have synchronized for this.

Tableau Butterfly Chart 13

Right-click on the axis and select the Edit Axis option.

Edit Primary Axis

It opens the Edit Axis window to change the range. As you see, by default, the synchronization selects the range automatically.

Edit Axis window to change the range 15

Let me change this option to Fixed and change the start value as 0 and end value as 347,101.602227. By this, both the Sales and Zero will be on the same scale.

Change Axis Option from Fixed to Value

You can see the Tableau Butterfly Chart.

Tableau Butterfly Chart 17

We have to do the same for the remaining Sales and Zero measures. So, right-click on the Zero measure and click the Dual Axis option.

Dual Axis Options

It almost completes the Butterfly Chart.

Tableau Butterfly Chart 19

Again, Right-click on the second axis and select the Edit Axis option.

Edit Secondary Axis

Here, we also changed the range from automatic to fixed, with 0 and 0 as the start and end values. Next, we also check-marked the logarithmic option.

Change Axis range from automatic to fixed

Changing the Marks from bar to text will show the text for the other half of this chart.

Tableau Butterfly Chart 23

We left it as it is, and you can see the final Tableau Butterfly Chart.

Tableau Butterfly Chart 24