6 Replies Latest reply on Mar 24, 2016 9:16 AM by Shawn Wallwork

    How to combine a heatmap with lat/long locations

    Sam Garbrecht

      Hello,

       

      I have been spending most of my day trying to figure out how to get a heat map and location map on the same visualization. I have tried Tableau as well as a few other visualization softwares and I have yet to find one that can do it. It seems like Tableau should be able to but poking around old forum questions I haven't yet found an answer to exactly what I am looking for. I have two different spreadsheets I am using for my data. One has our customers grouped by ZIP, county, and state. I can use that spreadsheet to create a heatmap like the one shown below that shows our concentration of members based on county.

       

      The second spreadsheet has some of our retailers down to their exact lat and long coordinates. Using this spreadsheet I can create a map with points for every retail location.

       

      I am wondering if it is possible to put both of these spreadsheets on the same map at once so the points overlay the heatmap. It sounds like the solution may require joining both of the spreadsheets into one but I have done that already and I can't find a way to get the exact store locations on the map without having to group them around ZIPs or counties.

        • 1. Re: How to combine a heatmap with lat/long locations
          Shawn Wallwork

          Sam, I remember having this exact same problem and spending a day(s) trying to work it out. Good news: It can be done!

           

          It will be easiest to explain to you if you provided a sample packaged workbook. But ultimately the answer is that you will be creating a Dual Axis map (Google search will show you how). And the lat/long fields you will use are going to be your Retailer custom fields (not the generated lat/longs).

           

          I hope this at least hints at a solution, but to help you farther we really need a packaged workbook.

           

          Cheers,

           

          --Shawn

          • 2. Re: How to combine a heatmap with lat/long locations
            Sam Garbrecht

            Hey Shawn,

             

            Thanks for the help. The solutions I came across were done using Dual Axis maps (so I did figure out how to make those) and there were a few that mentioned using the custom fields instead of the generated ones (that's how I got the location map in the second picture). But for some reason when I tried combining the two, it wasn't working. Here is a pared-down sample sheet. The first column indicates whether that row is a customer or a store. If it is a customer, there is a number in the households column indicating how many households are in that lat/long (the lat/long is simply the middle of a given zip code). That number is used to make the heat/intensity map which needs to be done at the county level.

             

            -Sam

            • 3. Re: How to combine a heatmap with lat/long locations
              Satish Kikani

              Tableau can create Heat map based on zip codes or up.

               

              in order to get the heat map you need, you will have to get zip codes for them and use them.

               

              Other solution is creating your own filled map.

              This thread might help. Area code mapping question

               

               

               

              EDIT: Based on reply above I think I am going to learn something new

              • 4. Re: How to combine a heatmap with lat/long locations
                Shawn Wallwork

                Thanks for the data (it always, always helps). It would have been just a wee bit better if you would have posted a packaged workbook that was already connected to the data, because I could have then figured out what version of Tableau you are using.

                 

                So find a 9.2 workbook attached. Here's what the viz looks like:

                 

                Is that what you were going for? Let me know if you have any questions.

                 

                Cheers,

                 

                --Shawn

                1 of 1 people found this helpful
                • 5. Re: How to combine a heatmap with lat/long locations
                  Sam Garbrecht

                  Hey Shawn thanks for the help. This worked perfectly once I played around a bit and figured out how to hide the customer dots that were showing up.

                   

                  One semi-related question that you may have experience with. The map worked great yesterday, but I saved the workbook and tried to open it today and it is not working. As you can see in the screenshot below if I put my mouse over the workbook tab at the bottom I can see the map in the little hover-over popup but the screen itself is just blank. Nothing I click will make the map populate. I saw online that this may be a firewall issue where I need to get the correct ports unblocked. Just want to see if you can confirm this is the issue because I don't want to waste our system admin's time on a wild goose chase.

                   

                  EDIT: Confirmed this isn't an issue with firewalls as far as I can tell. Connections to maps.tableausoftware.com are working just fine.

                  • 6. Re: How to combine a heatmap with lat/long locations
                    Shawn Wallwork

                    That read pill indicates that you have a broken field or calculation. The red exclamation points on those three fields, indicate that Tableau isn't finding those fields, which is probably why the pill in the viz is red. Go to the data connection and see what's going on. You may be connecting to a previous version of your file that doesn't have those fields. Edit the connection and point it at the correct workbook/sheet.

                     

                    Good Luck.

                     

                    --Shawn