How to Map Alaska… A Partially Successful Story

Recently on Twitter, local Philly viz enthusiast @CoreyJ34 asked if we could use @sirvizalot‘s Hex map technique to move the states around to get Alaska and Hawaii on a single map so that we don’t have to float elements. This is a particularly useful idea if we are thinking about a scenario where we swap between map types (standard, tile, hex). This is ultimately a blog post about several failures and a partial success.  But failing is amusing… so read on for your own amusement.

Here is the working version:

States on Top of the Hex Map

Taking this first step is very telling when we use the ‘filled shape’ on an XY.  All of the states are a uniform size. Even if we could figure out the positioning and dynamic size of each state, Alaska appears to be squished and looks worse when I make it larger. You might think that this would be good enough, but that’s because you don’t see that many of the states need to be tilted to fit together.




I guess I’ll make my own uniform sized states

While I have PowerPoint shapes at work for each state, that wasn’t available to me at home, so I made them to be consistent by using a free State Shaped font. I then found a decent looking map to use as a background pattern. The next step was super tedious to make individual images for each state and size them correctly (which included stretching and pulling them in odd ways to fit the projection.


Here is how absurd it looked when I lined them all up. I colored a few here just to make them stand out.



Here is how I put each tilted shape on a uniform transparent background so all of the states would scale correctly in Tableau.


Now I was finally able to bring in the appropriately sized, scaled, tilted shapes into Tableau. You can see that Alaska isn’t squished, Texas is at a slight angle, and Rhode Island is as small as I remember it. But here is where it failed for me, these shapes were so small and close together, with lots of transparent space that overlapped, I couldn’t easily hover over individual states. Certainly no where near the responsive nature of the native Tableau map. At this point I was feeling a bit deflated and decided it wasn’t worth mapping out all of the coordinates to line up these state images. Additionally, shapes only have a ‘halo’ option, and not an outline, so they really should be scaled to have a gap between them all and I’ve spent far too many hours on this crazy idea already.

After walking away from it for about 5 minutes, I had an idea to save the experiment. I could use the native map and just move Alaska and Hawaii. I found some coordinates that seemed reasonable (feel free to tell me some better ones) and used the state shapes I had created.



To get the states to show, I had to break them on the map. On the primary axis (contiguous states – Filled Map) I made Alaska/Hawaii null and then changed them to a meaningless string of number on the secondary axis (non-contiguous states – Shapes). Once I had done this, Tableau didn’t know where they should go. So I was able to enter a custom latitude/longitude without needing a full separate data set to position them.



Again because there is no outline on shapes, I had to use the halo if I wanted a solid color border on everything. It makes the halo on Alaska/Hawaii to look fuzzy to me.




So I decided to go with a white border on the states and no halo on Alaska/Hawaii. Bottom Line: you are probably better off floating the extra maps unless you really need a tile view for sheet swapping!  Here is the link to KB article to floating Alaska/Hawaii in additional maps.