Today we have been tasked with visualising socio-economic data from the independent ‘fact tank’ Gapminder. I chose to focus on a dataset showing the number of medical doctors per 1000 population. My partner works in healthcare and we often have animated discussions about resource allocation in the healthcare service, and I wanted to compare different countries to identify well-resourced and under-resourced countries and any clustering within the region.

Our challenge for the day was to complete all data cleaning and transformation using Tableau Prep – no Alteryx for quick and easy data manipulation today. I knew that I wanted to combine a hex map with line charts showing the trend overtime data for each country, to easily allow comparison of different countries. For each country to be large enough to be clearly visible I decided to focus in on European countries.

My limited use in Tableau prep involved pivoting numerous year columns (e.g. 1990, 1991, etc.) into a single column, joining my initial dataset with the global hex map template provided by Neil Richards (@theneilrichards), and filtering out any non-European data. I also removed Russia as this country distanced from mainland Europe in the hex map and would skew the visualisation.

Moving into Tableau, I set off on the task of creating a combined line-in-hex-map chart using the blog from Klaus Schulte as my inspiration.

Initially, I normalized the date year, providing me with a range of year numbers between 1 and 66

Next, I created two parameters called ‘Gap Column’ and ‘Gap Row’. These are float parameters with all values allowed and are used to tweak to the size of the line charts on the hex map.

Moving onto the line chart X-axis:

Followed by the line chart Y-axis:

Then calculating the position of the hexagons:

The resulting workbook looks like this:

I then tweaked the Column and Row gap parameters and formatted the workbook.

Full credit for this tutorial must go to Klaus Schulte and his original blog:

Lastly, I duplicated this hex map, resized it to be slightly larger, coloured the top three and bottom three countries. I then make both workbooks floating and hid the coloured hexmap behind the hex map with line chart to outline the desired countries.

My resulting dashboard looks like:

Link to Tableau Public:!/vizhome/EuropeanDoctorShortage/Dashboard?publish=yes

As always, all feedback is welcome!

Key Points from Today

I love hex maps

Tableau Prep is growing on me.

Avoid floating containers (I should know this already!)