Data4Democracy / usa-dashboard

A dashboard of key metrics for the USA
69 stars 27 forks source link

San Diego crime data #65

Closed srcole closed 7 years ago

srcole commented 7 years ago

I scraped crime data collected for San Diego (see issue #39).

Note that data is only available for the last 180 days, so this scraper needs to be run every 180 days in order to not miss any future data. This can be done easily by running download_latest_data.py.

Also note that the classifications for each crime provided by the San Diego Police Department were very specific, and not pre-categorized. So, by simply searching for the presence of keywords in the crime description, I assigned a category to each crime. The categories are: 'drug possession', 'fraud', 'vandalism', 'drunk in public', 'assault', 'burglary', 'motor vehicle theft', 'theft', 'sex crimes, not child-related', 'disorderly conduct', 'battery', 'other', 'driving under the influence', 'attempted murder', 'illegal conceal or carry of weapon', 'illegal sales, manufacture, or transport', 'arson', 'weapon-related crime', 'child-related crimes', 'murder'