On day 4 of our dashboard week, I worked on the top 250 movies from IMBD and decided to be more creative and take advantage of the time I had to build a radial bar chart. I had never built a chart like this before so wanted to challenge myself. I used this chart to display the number of movies that were created by date.
I used various tutorials online and decide to write a blog on it with the step by step to follow including formulas that you can use to copy
Before doing anything, we need to create a union using the same file. So, you just need to simply drag the same file and place it under it to create the union.
This will double up the records and we will need to create a path field to be able to draw the line
Simply click on the arrow in the table name that was created with the union and create a calculated field. The table name will pop up automatically and you just need to rename it Path order as an example.
The calculated field would be: the 0 would be the start of the line and 1 the end of the line
IIF([Table Name]=”Top 250 Movies.csv”,0,1)
You will just need to replace what is within the quote “” with your file name
You will need to create a couple of calculated fields but before doing so you will need to first change the chart for Line and drag the Path Order Calculated field in the path in the Marks card. (Calculated field should be a dimension) If not then change it to dimension
You now need to create 2 parameters. The first one is the Radial Inner and the second one is the Radial Outer as per below:
Few calculated fields need to be created.
The first calculated field : Radial Field which will be used in our other calculation: I used Record ID to represent the number of movies
Second calculated field : radial angle – (INDEX()-1)*(1/WINDOW_COUNT(COUNT([Radial Field])))*2*PI()
Third Calculated field: radial Normalised length – [Radial Inner] + IIF(ATTR([Path order])=0,0,COUNT([Radial Field])/WINDOW_MAX(COUNT([Radial Field]))* ([Radial outer]-[Radial Inner]))
Fourth Calculated field : Radial X – [radial Normalised length]*COS([radial angle])
Fifth Calculated field : Radial Y – [radial Normalised length]*SIN([radial angle])
Now it is time to start building the Radial Chart. Drag radial Y and Radial X in Columns and Rows. Drag your date (mine was date format) and change it to Continuous
Make sure you change your Radial Y and X using Compute using Date
Change both Axis and fixed it to -1 to 1
The radial chart will look like the one below and you can play around with the parameters to change the size of the Radial Inner or Outer.
For my example I used the count of Movies to display the colours in the chart
Final Step: Formatting
Now that you have the Radial Chart built you just need to format the sheet using formatting to remove all the lines and Axis.
You can now play around with the size and personalise the colour as you wish!