How to create a Radar Chart (Spider Chart) in Spotfire
Radar Chart (also known as Spider Chart) aren’t natively supported in Spotfire.
Here’s a way of creating a fully functionnal Radar Chart using a Scatter Plot and some basic mathematics in Spotfire.
This tutorial will use R’s Motor Trend Car Road Tests dataset (info and csv). The main Idea is to use the Polar coordinate system (note : a radar chart is also known as a polar chart) in order to represent each point
We will have to unpivot the dataset and calculate an angle (Val r
) and a radius (Cat θ
) :
Val r : [Value] / Max([Value]) OVER ([Category])
Cat θ : Rank([Category]) / Max(Rank([Category])) * 2 * PI()
This allows us to create an x-axis and an y-axis using trigonometry :
rad_x : [Val r] * cos([Cat θ])
rad_y : [Val r] * sin([Cat θ])
Then, you can use the « Lines&Curves » chart option to trace a line between each point :
As usual, the Spotfire Analysis is available as a dxp file here : Spotfire Radar Chart / Spider Chart Example.dxp
Hello,
This visualisation looks very great. Unfortunately, We can’t access the file.
Could you please share it?
Thx
Rgds!
Thank’s Guillaume,
Here’s an alternative link to the dxp : http://datactuariat.fr/go/radarchartdxp2
If you want a step-by-step tutorial on how to replicate this, you can find my answer to a redditor here : https://www.reddit.com/r/spotfire/comments/5u89oc/how_to_create_a_radar_chart_spider_chart_in/
BR
Benjamin
Hello,
Thanks a lot. Very useful for « starters ».
Have nice day!