Toan Hoang

Half-Circle Charts in Tableau

Now we are in the full swing of things I wanted to create a nice and simple visualisation for comparing two different metrics i.e. through drawing two half-circles and comparing them against each other. In this tutorial, we will go through the process of creating this visualization in a simple step-by-step manner.

Note: As always never choose a data visualisation type and try to fit your data into it, instead, understand your data and choose the best visualization for your data consumers.

Data

Load the following data into Tableau Desktop / Public.

ProductPathSales
Office0800
Office180800
Home0500
Home180500

Note: we need two records for each stage as we are going to be drawing polygons and using densification to get more points on our canvas.

Calculated Fields

With our data set loaded into Tableau, we are going to create the following Calculated Fields and Bins:

Path (bins)

Index

INDEX()-1

Product Flag

WINDOW_MAX( IIF(MAX([Product])="Office",-1,1))

TC_Max Sales

WINDOW_MAX(MAX({ FIXED : MAX([Sales]) } ))

TC_Product Sales

WINDOW_MAX(MAX([Sales]))

TC_Percentage

[TC_Product Sales]/[TC_Max Sales]

X

SIN([Index]*PI()/180)*[TC_Percentage]*[Product Flag]

Y

COS([Index]*PI()/180)*[TC_Percentage]*[Product Flag]

So with our Calculated Fields in place, let us start creating our worksheet.

Worksheet

We will now build our worksheet:

You should get something like the following:

We will now adjust the worksheet by:

You want to end up with the following:

and boom, we are done, we have created an interesting way of comparing two different metrics using half circles.

You can see and interact with my visualisation on Tableau Public at https://public.tableau.com/profile/toan.hoang#!/vizhome/Half-Circles/Half-Circles

Summary

I hope you all enjoyed this article as much as I enjoyed writing it, if so, please do share this article with fellow Tableau addicts and spread the love. Do let me know if you experienced any issues recreating this Visualisation, and as always, please leave a comment below or reach out to me on Twitter @Tableau_Magic.

If you like our work, do consider supporting us on Patreon, and for supporting us, we will give you early access to tutorials, exclusive videos, as well as access to current and future courses on Udemy:

Also, do be sure to check out our various courses:

Exit mobile version