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.
Tableau Butterfly Chart Video
Next, drop the Sales measure into the column shelf multiple times. By default, it displays two horizontal bar plots side-by-side.
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.
We named the calculated field as Zero and placed 0, which means it shows zeros.
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.
Convert the Circles of Zero field to Bars using Marks shelf.
Next, we are converting the remaining column measure fields to bar charts by changing Marks.
Now, you can see the Bar graphs. We have to convert this to Tableau Butterfly Chart.
Let me change the Zero field to Tableau Text or labels.
As its value is 0, it shows Abc as the text.
Select and right-click on the Sales field, zero fields, and select Synchronize Axis option.
Now the data of both the measures have synchronized for this.
Right-click on the axis and select the Edit Axis option.
It opens the Edit Axis window to change the range. As you see, by default, the synchronization selects the range automatically.
Let me change this option to Fixed and change the start value to 0 and the end value to 347,101.602227. By this, both the Sales and Zero will be on the same scale.
You can see the Tableau Butterfly Chart.
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.
It almost completes the Tableau Butterfly Chart.
Again, Right-click on the second axis and select the Edit Axis option.
Here, we also changed the range from automatic to fixed, with 0 and 0 as the start and end values. Next, we also checkmarked the logarithmic option.
Changing the Marks from bar to text will show the text for the other half of this chart.
We left it as it is, and you can see the final Tableau Butterfly Chart.