Stay Safe, Kids! Using Data to Avoid Crime Hotspots

tableau crime map
Friday, August 30, 2013 - 09:45

I have lived on the south side of Chicago for almost four years now. Upon moving to this area, I quickly learned the best, and safest, ways to get around the city. For the following visualizations, I decided to see if I could find some empirical data to support the local truisms of which corners are safe and which should be avoided.

From, I downloaded into Microsoft Excel two tables of information. The first table contained information on the 11,593 CTA bus stops in the city of Chicago. The second table contained information on crimes reported this year (as of early July, 2013). I classified crimes as being violent (Assault, Battery, Homicide, Criminal Sexual Assault, and Robbery) or non-violent (all others). Both of these tables contained location information in the form of latitude and longitude coordinates. Using Pentaho Data Integration and MySQL, I used this information to compute how many crimes were committed within a certain radius of each bus stop.

I then combined my tables with crime information and bus stop information into one Excel spreadsheet. I loaded this table into Tableau so as to easily display this information on a map of Chicago. Within Tableau, I created a new dimension which tagged crimes as such, and bus stops as low, moderate, or high crime areas based on how many crimes were committed within my specified radius. The first map below shows all crimes, with violent crimes represented by red dots, and non-violent crimes represented by blue dots.

The map above is a bit cluttered, and it is difficult to draw conclusions based on this image alone. Therefore, I created the two following maps that indicate crime levels using CTA bus stops. The first map is based on violent crimes and the second is based on non-violent crimes. Each bus stop is color coded green, orange, or red if it is in a low, moderate, or high crime area respectively. The size of the dot representing each bus stop is determined by the number of crimes committed nearby, with higher crime areas having larger dots.  

Not surprisingly, the loop has high levels of non-violent crime but much less violent crime. Also as expected, South and West Chicago are shown to have high levels of both violent and non-violent crime. There does appear to be more violent crime on the North Side than one might expect. I suspected that Wrigley Field may have played a role in this, so for the next map, I have zoomed in on the Wrigleyville neighborhood.

You can see that there is a high amount of crime on the corners closest to Wrigley Field, while the rest of this neighborhood has the low crime levels that one would expect on the North Side.
I have also enabled the ability to filter based on the type of crime committed and based on bus routes. In the maps above, I have filtered out all types of crimes so as to not clutter the map, but I did not filter any of the bus routes. In the map below, I show four of the bus routes that I most frequently use, and include the location of robberies committed this year, which are indicated by blue dots on the map.

In the last map, I have focused in on the area surrounding the University of Chicago, where I attended college from 2009-2013.  

This map shows that the areas to the south and west of the university, show high levels of violent crime, while north and east of the university are much safer. This is consistent with the beliefs of the student population, as many students travelling downtown prefer to travel east to the Metra or 6 bus route, as opposed to traveling west to take the Red or Green Line downtown.

I hope that the images above have demonstrated the power of these analytical tools. By using Tableau, Pentaho Data Integration, and MySQL, I was able to quickly draw conclusions from 10,000’s of rows of information that were previously in need of context and accessibility.

Contact us today to find out how Inquidia can show you how to collect, integrate and enrich your data. We do data. You can, too.

Would you like to know more?

Sign up for our fascinating (albeit infrequent) emails. Get the latest news, tips, tricks and other cool info from Inquidia.