Our data is dynamic and the axis by default in Tableau will change accordingly. For example, in this
Fibonacci Spiral chart, the chart and the grid are changing from iteration to iteration. This creates some visual uneasiness and can even make viewers dizzy.
The goal here is dual:
- keep the origin at the center of the grid
- make both axis the same scale
Both should be done dynamically
The options in the axis editor won't help.
So, here I would describe a technique to keep the origin fixed. I learned this when tweaking the
Fibonacci viz by Zen Master Noah Salvaterra who used this technique. All credits go to Noah.
1.Make the X axis symmetric vs 0
- Control-drag the [x spiral axis] to the Details shelf. Right click the pill and select Edit in Shelf to add a negative sign -[x spiral axis]. This way we keep the table calculations settings the same.
- On X axis, add a reference line based on the Minimum of -[x spiral axis]. Make the reference line invisible by hiding Label and Line in the editor.
- Add another reference line based on the Maximum of -[x spiral axis].
2.Make the Y axis symmetric vs 0
- Do the same as above on Y axis. Use -[y spiral axis] instead.
After the above 2 steps, the origin will be in the center. But the scales of the two axis are different. Thus a circle may look like an ellipse. To have a Cartesian grid, we need to make both axis the same scale.
The key is to have X axis range be governed by the range of [y spiral axis]. Vice versa for Y axis. All these must be done dynamically according to the data value range. So here is the 3rd step.
3.Make both axis the same scale
- Control-drag both [x spiral axis] and [y spiral axis] to the Details shelf
- On X axis, add 4 more reference lines based on Min, Max of [y spiral axis] and Min, Max of -[y spiral axis]
- Same for Y axis using [x spiral axis] and -[x spiral axis]
Voila, the Fibonacci Spiral will spin around a fixed origin from iteration to iteration, while both axis will scale accordingly in sync.
Add a comment