1 2 3 Previous Next 37 Replies Latest reply on Jun 24, 2013 8:52 AM by Shawn Wallwork

    Dual Axis Maps

    Shawn Wallwork

      When using a dual axis map the Label and Size Marks on each of the latitudes are independent of each other and can be assigned different attributes (see attached). This works well. But the Color marks are tied together. It sure would be nice if the Color Marks were also independent of each other -- so in this case the store dots could be black, while the ZIP Code fills retained their fill colors based on measures. This would also allow the ZIP fills to be washed out revealing more of the map below, while the black store dots could be kept at 100%. --Shawn

        • 1. Re: Dual Axis Maps
          Richard Leeke

          Actually colour is independent, too.  What is happening here is that you have the mark type set to filled maps for both of the dual axes.  So for the marks for which Tableau does have polygons (the ones where it knows about zip code) it displays a filled shape, but where there are no polygons defined for your stores, it just puts a dot.


          I think you're pushing the outer reaches of what Tableau is designed to cope with here, but there are a few things you can do, as in the attached version (note that I removed that 2 MB background map to save space).


          If you just change the mark type to a shape for the axis showing the stores you get dots and you can control the colour, as I've done in the first sheet.  But  with the data as you have it structured that also results in a dot smack in the middle of your zip labels.  (But see below, this isn't so bad after all.)


          Next approach - move the dots for the zips off the area of the map (see calculated lat/long fields).  The filled shapes are still going to be drawn based on geocoding polygons, so they stay put.  But that has the effect that the zip labels move off the map along with the zip dots, so that's no use.


          3rd approach (and I've only mocked something up to demonstrate this - slightly too much effort to set it up) is that you could use custom geocoding for your store locations.  That way you wouldn't need to include any lat/long in your main data, just zip codes and store names.  You would then drop zip code on level of detail for the filled map mark and store name for the other one.  You would want to show the "missing zips" (corresponding to the stores) at the default location for the zip map and the missing stores (corresponding to the zips) at the default location for the store map.  That approach gets rids of the zip dots.


          I just realised that the dots can be made so small that they barely show for the zip codes in the first approach, by just using the size shelf, so I would probably ignore all the rest of that - but it might be useful info anyway, so I've left it.

          • 2. Re: Dual Axis Maps
            Shawn Wallwork

            Richard nice little trick you did with the size shelf! And as always it's an education whenever you work on my stuff, thanks for that. Using the shapes mark had an added benefit, I got rid of 'Store' and substituted their logo, clients love that sort of thing ;) (see attached). And I can absolutely live with the tiny dots in the ZIP labels.


            Thanks for removing the background map I forgot it was still in there. Which brings up another one of my wishlist items. I wish you could put filled ZIP codes over a background image map. When I try the polygons fly apart and display as an unorganized mash-up control by the size slider. I mentioned this in the Beta trials, and Francois said that it is a design feature so you can do interesting tables with geo-shapes. Of course I don't thinks anyone is going to recognize ZIP Codes by shape, and probably not county for that matter. So this really only works for States and countries, which is sort of a limited use, for what could otherwise be a very handy tool. Anyway I digress.


            Hope your Monday is off to a good start. It's time for a little Sunday afternoon American Football for me.




            • 3. Re: Dual Axis Maps
              Richard Leeke

              I agree about the flying shapes - not really that recognisable except for a few very obvious countries and states.


              Public Holiday here so a lazy start (hence having the time to play with your map!).  But there's blue sky and lots of wind so I'm off windsurfing shortly...

              • 4. Re: Dual Axis Maps
                Gregg Thomas

                Blue sky & windsurfing sounds fantastic...I'm in the States in Michigan and the forecast is calling for 5-8 inches of snow tonight!


                I'm loving this map...to complicate it even further, suppose I wanted to add a distance filter.  So I could filter on showing the location data that are 1, 2, 3, etc miles from each store?  Any suggestions? 




                • 5. Re: Dual Axis Maps
                  Richard Leeke

                  Robert Mundigl wrote a couple of great postings about how to do this back in Tableau 5 and Tableau 6 days on his Cleary and Simply blog site.  The version 6 posting is here.  I then did a series of 3 follow postings discussing ways of getting around some issues which Robert was finding doing it in version 6.  The start of that series is here.


                  That is all quite heavy going and probably covers more topics than you are asking about.  I vaguely recall that there may be a more recent knowledgebase article or forum post which just focuses on the filtering to a distance, but I can't think where to look.

                  • 6. Re: Dual Axis Maps
                    Tim Latendress

                    This is great stuff guys!  I think I can get some mileage out of using these techniques with our banking data.


                    One problem I ran into was when I opened the Geocode Stores worksheet I received this pop-up message. There is a user here who just asked me about the same error message (which is how I ended up finding this posting while researching a solution).  Have either of you seen this one before?


                    I should add that I am using 7.0.1.

                    • 7. Re: Dual Axis Maps
                      Richard Leeke

                      I haven't ever seen the message before, but I can explain what it means.


                      When you define custom geocoding, Tableau makes a complete copy of it's built-in custom geocoding database and then adds more tables holding your custom geographic roles.  Any workbooks that reference those custom roles will use the custom geocoding database for everything (i.e. built-in roles like Country and State as well as your new roles) rather than using the built-in one.


                      From that message it looks to me as if you must have a workbook that was built using version 6, so has a custom geocoding database which is based on the version geocoding.  That did not have support for filled maps - so even though you are now using version 7, it can't draw filled maps for its built-in roles.  I believe that you will need to regenerate your custom geocoding using version 7.


                      Note that you still won't get filled maps for your custom roles unless you resort to the hack which I posted about on Viz Talk the other day. Or you can draw your own filled maps using polygons, as Joe Mako has talked about in the past.

                      • 8. Re: Dual Axis Maps
                        Tim Latendress



                        I am just getting back to this thread -- thanks so much for the response. I actually received this message when I opened the workbook posted above. I made no changes at all.


                        I wonder if Tableau Desktop is scanning for any custom geocoding regardless of whether it is being used in the current workbook?  That might explain it as we have used custom geocoding in past workbooks.  I think this will require a little deeper digging on my part to determine where those files are stored and do a couple of tests to see if removing the files fixes the problem.


                        I will post my results.

                        • 9. Re: Dual Axis Maps
                          Richard Leeke

                          OK, I see what happened - though it does seem a bit odd.


                          You must have added custom geocoding back in version 6 days - so you have a version format custom geocoding database in your repository.


                          Shawn's workbook uses filled maps - but not custom geocoding, For some reason when you switch to the third tab it tries to use your version custom geocoding database, rather than just the built in version 7 geocoding.


                          Simply select Map->Geocoding->Remove Custom Geocoding and it will stop happening.

                          • 10. Re: Dual Axis Maps
                            Tim Latendress

                            It is very odd that Tableau checks for any custom geocoding in the directory regardless of whether I am actually using it in a viz. But your solution worked perfectly!


                            Thanks, Richard.

                            • 11. Re: Dual Axis Maps
                              Barbara Willett

                              I'm really having trouble with this labeling issue - I didn't have a problem with earlier versions of Tableau - I just want one label for the countries on my map - not three (per the detail of my color and  shape marks).  But I can't figure out this whole Dual Axis feature - seems way too complicated for a simple thing.   But I need a fix fast!

                              • 12. Re: Dual Axis Maps
                                Shawn Wallwork

                                On the marks shelf you'll have two Latitude (generated) and an All header, like this:


                                Marks Card.png

                                First take your Countries label off the All. Then open one of the Latitude (generated) headers, and put the Countries label on Label field. This will give you 1 label instead of 3.

                                • 13. Re: Dual Axis Maps
                                  David. Lewis

                                  Hi all:  Great threads on these topics, most of which seem to feature Richard.  Thanks much for sharing all you hard work.

                                  I am working on something very similar to the 'stores_data_by_zip' from last year, and wonder if the issue is the way I've structured the data.  I've attached the twbx for reference, if anyone cares to look.

                                  Basically I have two data sources, one of shapefiles loaded into tableau of the california census tracts, with some demographic information, and a second data source with a selection of chain stores, with addresses, etc (also Lat Long).  Eventually I hope to build something similar to 'stores_data...' but at the moment I am struggling to get dots representing store locations (using their lat/longs) on the custom filled polygon map. 

                                  I suspect that the issue is related to the fact that the data is in two different datasets, and, crucially, they cannot be linked, in their present form, at the appropriate level of detail (the polygon/tract level).  Is that correct? 

                                  The GEO_ID field in the polygon dataset (eg 1500000US060070016001 for a given census tract) is unique to each polygon, and I will soon (in a few weeks, I think) be able to add that to the chain store dataset (ie locate each chain outlet within a given GEO_ID, in addition to having the store's precise lat/long).  Once I do that, I can create a relationship between the two datasets.  Is that the last step that is preventing me from creating a 'Points on Polygon' type viz?  Many thanks for any replies.


                                  I'm trying to upload a twbx but can't find a way to do it right now.  As soon as I do, I'll post it.


                                  D. Lewis

                                  • 14. Re: Re: Dual Axis Maps
                                    Shawn Wallwork

                                    Click here:



                                    Then at the bottom, of the new editor click here:





                                    1 2 3 Previous Next