4 Replies Latest reply on Nov 12, 2012 12:02 PM by Shawn Wallwork

    Another question about Map Zooming

    Justin Smith

      Hi all,


      I am working with a background image that is a map of my school. I've successfully plotted various points that represent rooms, and have a quick filter so a user can select the room they are looking for.


      The problem is, upon selection, the map adjusts to only include that point and zooms a very small amount. VERY small amount. Is there anyway to adjust how far it zooms in on selection? I have adjusted the size of the shape that indicates the point to at least make it viewable at this zoom level, but ideally it would zoom in quite a bit more.


      Thanks in advance,


        • 1. Re: Another question about Map Zooming
          Shawn Wallwork

          Justin can you scrub out the sensitive data and post a packaged workbook? Do you have a filter action set up? If not try that, it should give you what you want.



          • 2. Re: Another question about Map Zooming
            Richard Leeke

            The issue is probably just that Tableau has no way of knowing how large an area around your room "makes sense" to display. If you have selected a single room, and that is represented as a single point, Tableau will have no basis to know the scale to use - does that point represent the centre of a country, the centre of a city or the centre of a molecule?


            If you select 2 or more points, Tableau will draw an area that encloses all the points with some "reasonable" buffer around it. Several versions of Tableau ago I remember postings about similar issues if you select just a single row from one of the geographic types that Tableau knows about - a State or a City, say. These days that isn't an issue because Tableau has some smart built in which allow it to make sensible guesses about the area you want around those built-in types. Or if you select a single mark on a filled map (a State, say) it knows the boundary points, so it knows the area to surround.


            But if you only select a single point and Tableau doesn't know what that point represents, I don't know what basis it uses to zoom.


            The only thing I can think of is that you might need to include multiple marks per room - the coordinates of the 4 corners of the room, say.

            • 3. Re: Another question about Map Zooming
              Justin Smith

              Thanks for your interest in helping. After I got everything pointed out, the zoom level actually works well enough for my project.


              The only issue I have is I would like it to zoom of the wing selected, but not omit the surrounding rooms. See attached. For example, if I select wing "A" and all rooms, the "C" wing rooms cannot display information when moused over. I know this is because the selection of a wing omits the others, but is there a way to zoom based on that selection without omitting others? I feel this may be worthy of a new post, but if either of you have a suggestion, I'll take it!


              Thanks again,


              • 4. Re: Another question about Map Zooming
                Shawn Wallwork

                Hey Justin. This is an interesting problem. I think if you take Richard's idea of padding out the view with marks to get the zoom level you want, you can make this work. But the 'registration' marks have to be completely separate of the marks you're using to pop-up the tool tips.


                So zoom to whatever view you want, note the values of the four corners, and put these values into the Registration Marks column in your data set. Either set the wings labels up in the data set, or alias them in Tableau. When you filter on the Registration Marks, you won't be effecting the tool tip marks, so you should get the user experience you're looking for. Also you'll get better control over what exact zoom level/view you'll be displaying.


                Hope this made sense, and helps.




                PS: You could also probably create calculated fields to create your registration 'windows' and then use a parameter to drive the zoom, but that something either ZM Richard or Jonathan can help you with.


                PPS: Either of these is probably a dual axis map, I think, but this is getting a bit like playing chess without any pieces on the board!