When it comes to shapes , there are studies that suggest humans are more inclined to slight curves. It comes as no surprise with the popularity of  visualization that has curves or arcs in it. It gives a WOW factor. The usability  of such charts may be questionable, but I bet you will like a curved bump chart more than an ordinary bump chart.

Curved lines are not available in tableau and creating them requires some effort. So lets start simple. Draw a circle ? . Learn the basics and go on to create some stunning custom charts!!!!!!!!

This blog will give a basic understanding of creating custom charts using the X and Y Coordinates. Most of the custom charts like Radial bar chart, Polar chart, curved Bump chart  etc. use the  X and Y coordinates to plot arcs or curves or circle in tableau.

We are just using a dummy dataset for this.

Dataset

For this we will use  1 dummy  record

Name Value
Circle 1

Import the data into tableau. Union the data with itself. This is known as data densification. With just 2 rows we get enough points to plot a circle !!!!

Create calculated field

Path

if [Table Name]=’Sheet1′

then 1

ELSE 360

END

–This field is for creating 360 points. We will be creating (X,Y) values for 360 points and plot the circle.

The (X,Y) coordinates of a circle with radius R is

   X= R COS θ  ,Y= R SIN θ

Lets create the required fields in tableau now. From Path, Create Path Bin with size of bin as 1.

       

Create calculated field

Index

INDEX()-1               — set compute using to Path(bin). This will give value from 0-259 for Index.  For each of the Index points , we will create Radian(or angle), X and Y value

Radians

[index]*PI()/180    — angle in radians at which each point is plotted.

X

2*cos([Radians])    — 2 is the radius of the circle.

Y

2*sin([Radians])

Its time to create the circle. Drag and drop Path Bin to Rows . Right click and ‘Show Missing Values’.

Drag path(bin) to details. Drag X to rows and Y to Columns. Set compute using to Path(bin). Change the mark type to circle. And we have the circle 🙂

Watch this space for more custom charts!!!!!!!!!!!!

Asha Surabhi
Author: Asha Surabhi