Now in its fourth year, Azavea’s Summer of Maps Program has become an important resource for non-profits and student GIS analysts alike. Non-profits receive pro bono spatial analysis work that can enhance their organizational decision-making processes and programmatic activities, while students benefit from Azavea mentors’ expertise. This year, three fellows worked on projects for six organizations that spanned a variety of topics and geographic regions. This blog series documents some of their accomplishments and challenges during their fellowship. Our 2015 sponsors Esri, Temple University Geography and Urban Professional Masters Studies Program and Betsy and Jesse Fink helped make this program possible. For more information about the program, please visit the Summer of Maps website.
As part of Azavea’s Summer of Maps program, I worked with the Legal Clinic for the Disabled, a pro bono legal organization that serves low-income individuals with disabilities in the greater Philadelphia area. The Legal Clinic for the Disabled (LCD) wanted to compare their client intake records with publicly-available geographic data in ways that would inform their future intake and services.
LCD was particularly interested in the relationship between poverty, disability, and unsafe housing conditions. They had every right to be: a 2014 report shows that people with disabilities face enormous challenges in the search for affordable and accessible housing. Individuals living on disability payments alone are priced out of the rental market in almost all major cities. This means that if they do find an affordable place to live, they may have less leverage against a negligent landlord. Poor housing conditions may also increase the likelihood of developing a disability: researchers at the Cincinnati Children’s Hospital Medical Center found a positive correlation between the density of housing violations and the number of childhood asthma cases in an area. If LCD could identify links between clusters of substandard housing and clusters of disability in Philadelphia, they could advocate for improved housing conditions in those specific clusters or even use the links as evidence in a legal case.
Philadelphia is fortunate to have an enormous source of publicly-available housing data at its fingertips: the Licenses and Inspections data set, which covers all housing permits and code violations within the city, can be viewed for free online. Currently, this data can be accessed by using the Licenses and Inspections API, or through the friendlier License to Inspect tool. However, the API (application programming interface) only allows users to view a maximum of 1,000 records at a time, while License to Inspect offers no way to directly view housing violations. I needed all of the violations and their details in my own database for statistical analysis.
I built a web scraper using the Python programming language to extract all of the violations from the Licenses and Inspections API into a single comma-separated values (CSV) document. In all, I extracted 1,079,788 violation records. I identified 2,165 records erroneous and placed them in a separate file. I placed the rest of the file on GitHub for anyone to download.
This map shows the density of all L&I violations in Philadelphia over a 10-year period, using a neighborhood radius of 500 meters:
Compare that to the following map, which shows the population density of city residents living under 150% of the poverty line:
Each record represents a single violation, which can be grouped by License and Inspection case or by location. The 1,077,623 valid records that I surveyed were grouped into 368,574 different cases and 157,350 different locations. That works out to an average of 7 violations per location, but there were some outliers: the top 0.1% of locations had an average of 141 violations each!
Violations and cases could also be broken down by a number of descriptive categories. For example, based on their threat to human safety, violations are given a priority from “Non-Hazardous” (less severe) to “Imminently Dangerous” (the structure might actually fall). Here is the breakdown for the violations I extracted:
Construction Services 5.2%
Imminently Dangerous 1.2%
And finally, in case you’re concerned about the “Imminently Dangerous” designation, here’s a density map showing only those violations:
Housing justice is vital not just to LCD’s mission, but to many nonprofits and advocacy groups in Philadelphia. Hopefully, this collection Licenses and Inspections data will allow more groups to better understand housing conditions throughout the city.