Part One: Defining Neighborhoods
Regardless of what metropolitan area you may be most familiar with, one common nuisance is the dreaded parking ticket. Whether you don't feed the meter in time, pick the wrong space, or flip the bird to a parking enforcement officer, parking tickets are very easy to get. In fact, in the city of Milwaukee hundreds of thousands of parking tickets are issued every year!
Over the next couple of weeks we are going to do a deep dive into this issue for the good land, Milwaukee.
The first step that we will complete this week is to define Milwaukee neighborhoods for aggregation. In order to do this we have to create custom polygons for Tableau's map. This is an arduous process, but a cool feature to use!
The first step is to set up an Excel sheet with the proper columns for the map. In our case, we need to capture the neighborhood (the name of the polygon), the order of the points (think of a connect-the-dots image), the shape ID (only needed if you have non-contiguous shapes, which we do), the latitude, and the longitude.
One this is done, we need to find a map of neighborhoods (unless you know them already). In my case, I used the map below to approximate neighborhood starts and stops (note: I did take some liberties, but my end product is very similar).
After obtaining the map, I used Google Maps to approximate the points for each neighborhood's boundaries. This is a tedious task, so if you would like to get approximate Milwaukee neighborhood points please contact me at email@example.com and I would be happy to e-mail you the raw data!
After all of this is done, we are ready for Tableau! To begin, make sure that all of your fields other than longitude and latitude are dimensions. You will probably have to make some changes for this to happen. Once your data is categorized properly, conduct the following steps.
- Set the mark type to "Polygon"
- Drag the field with the sequence of your points (in my case it is Point Order) to the path card
- Drag the shape ID (or the neighborhood if yours are contiguous) to the detail card
- Drag the neighborhood to the color card
- Double-click on longitude and latitude to bring them into the viz
And there you have it, we have our neighborhoods defined! Next week we will use this map to analyze our parking tickets to draw some conclusions.
Author: Chris Bick