top of page
Writer's pictureSimon Beaumont

#IronVizLearning - Dual axis labelling with Index()


Welcome to the 2nd post in my #IronVizLearning blog series, where I share what I learned during the 2020 Health and Wellbeing #IronViz global feeder (you can access the first post here). I will continue to share short posts focusing on specific design / functional techniques with the series culminating in a larger post, sharing my overall design approach for the viz.


In this post I focus on the explorer chart at the foot of my Human Development Index visualiation. The explorer chart ordered countries within each region by their Human Development Index Score, whilst allowing you to specify parameters to highlight countries on the chart that met a range of criteria (for example a minimum life expectancy, or a population range).


To sort countries, within each region, I used an Index() technique that I learned from Hesham Eissa during his Data School placement within the JLL BI Centre of Excellence:

  • Place Region on Columns

  • Country on Detail within the Marks Card and order this by the Human Development Index (descending), or alternatively your desired measure

  • Now place Index() on Rows and edit the Table Calculation to compute using the specific dimensions of Region and Country, at the level Deepest and restarting every Region

  • Finally I placed my Human Development Index Quartile calculation onto colour to allow people to easily identify those countries in the top 25%, 50% etc of HDI scores.

This achieved the following visual:

All good so far, but how would people know which bar related to which country? The last thing I wanted was for people to have to hover over each bar to achieve this. Likewise I could not simply place the country ISO code on label for the bars, this would display the country ISO code either inside of the bar, to the left, or outside the bar, to the right. I decided against both of these as the inner option made it difficult to read the text when overlaid on the colour range, and the outer option was visually unappealing as the labels were aligned based on the HDI value and not aligned vertically down the screen.

I needed to come up with an alternative that placed the labels to the left of the bars, similar to the style achieved when placing a dimension on rows (a technique that is not compatible when using the Index function to sort.


And so we arrive to my #IronVizLearning.


You will note the x axis displays between 0 and 1, the range of possible values in the Human Development Index. I placed a secondary measure on Columns [max(-0.025] and made this a dual, synchronised axis with the HDI value that was already placed on Columns


Next I fixed the axis range to start at -0.25 and end at 1.1 and I used the axis labelling trick described in my first #IronVizLearning post to only label 0 and 1 (achieved by setting the Tick Origin as 0 and the Tick Interval as 1).


I set the secondary measure to a Bar and made this bar transparent (so no point was visible) and then ticked show mark label, aligning to the left and specifying a desired colour.


Hey presto (I still cant ever write that without thinking of our #DataFam superstar Josh Preston!), looking at the final chart below, you can see the country ISO code is left aligned, before the chart, despite the fact there is no traditional dimension placed in rows within the sheet.


If you want to check out my final #IronViz visualisation you can do so here.


In my next post I will share a twist on a lollipop chart that I utilised to show the variation across the 3 dimension of the Human Development Index.

139 views0 comments

Recent Posts

See All

Comments


bottom of page