Rody Zakovich created a polygon-based hex map because he found that the shape-based hex map (created by Matt Chambers) can be hard to align and scale.

 By looking into Rody's template, I found something to tweak. I created here two versions of the hex map. Both uses smaller data sizes. Note that originally each hexagon needs 6 points thus 6 rows of data. Here you go.

1.Label without extra 51 rows 
Rody used an extra 51 rows solely for the state labels. I found a way to label without the extra rows.

First, drag avg(X) and avg(Y) to Columns and Rows shelves respectively with State in Details and Point in Path, while the data mark is Polygon.

Second, use avg(Y) for the vertical position of the label. Put Abbreviation in Label shelf. So we get the labels right in the middle. Note we need to select Circle as mark and make the color 100% transparent.

Third, blend with a data file and use a select measure to color the hexagons.

2.Two rows per state
In Rody's hex map, each state requires 6 rows per polygon thus per state. Here I applied densification to the construction of the hexagons. Thus only 2 rows are required per hexagon or per state.

Here are the steps.
Step 1
Create one-mark-per-state data set where each mark is positioned at the center of one hexagon.
We got 51 rows here: 50 states + DC.

Step 2 
Load the data set into Tableau and union with itself. We got 102 rows here. That's all we need.
The resulting data set is like below.
Step 3
Create Point field to be 1 and 6. Then create Point (bin) from Point to go from 1 to 6.

Step 4
Create X and Y for each of the 6 vertices of hexagons.
Step 5
To trigger densification, we need put Point(bin) on Row shelf first. Right click and select Show Missing Values. Then drag it to the Path shelf of Polygon data marks.

Step 6
Use Dual Axis to label the hexagons. The labeling is easy because we have already the coordinates of the center of the hexagons. Note we need to select a circle mark and make the color 100% transparent.

Step 7
Blend with a data file and use a select measure to color the map.

BTW, Joshua Mulligan's spatial file-based hex map is really cool. One may not need all these above. I wrote these simply for personal research interest and show one of the many ways to create a hex map.

And I noticed someone left a message at the end of Rody's article asking for detailed steps. If someone is creating hex map for other countries or regions, he may not have the luxury to create or find spatial files. Hope this can help.

The workbook can be downloaded from here.
0

Add a comment

(Refresh the page if you want to view the gif image multiple times. Or go to Tableau Public and click the button at the top-right corner.)

Jake and I collaborated on a dashboard. He told me that he learnt a way to create an in-place help page in Tableau. He first saw it at a conference somewhere and couldn't recall who the speaker was. So I am blogging here about it but the credit goes to somebody else. If anyone knows who the original creator is, leave a comment below.

The key idea is to float a semi transparent worksheet on top of the dashboard, where a help text box is strategically placed on top of each chart. This way, we can explain how to view each chart and what data points are important, etc. This worksheet is collapsible by a show/hide button. 

Below I would like to show how this worksheet can be constructed.

1. Sheet with a single data mark.

  • Double click the empty space in Marks panel and add two single quotes. Make the null pill a text label. This creates a single null mark.
  • Set the view as "Entire View"

2. Create an show/hide button

  • Go to the target dashboard
  • Drag a floating vertical container to the dashboard, making it cover all the area of interest.
  • Drag the Single Null Mark sheet and drop it into the above container. Hide the sheet title.
  • Create an open/close button for the container and place the button at the top-right corner.

3. Add annotations

  • Format the sheet background opacity as 70% in the layout manager             
  • Select area annotations and place them anywhere of interest. 
  • Write help text and format it to highlight important messages.  
  • The text can serve as functional guide and/or insight guide.

Here is an example. Feel free to download the workbook and explore. Click the "i" button at the top-right corner to view the in-place help. 

0

Add a comment

Blog Archive
Loading
Dynamic Views theme. Powered by Blogger. Report Abuse.