Skip to content

zingbot/nypd-crash-data-bandaid

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NYPD Crash Data Bandaid

NYPD traffic collision data has a booboo. This eases the pain.

Council Member Jessica Lappin got into an animated discussion with Petito over traffic crash data. When Lappin asked why NYPD is releasing data in PDF form — and only after the council adopted legislation forcing the department to do so — Petito replied that the department is "concerned with the integrity of the data itself." Petito said NYPD believes data released on a spreadsheet could be manipulated by people who want "to make a point of some sort." An incredulous Lappin assured Petito that the public only wants to analyze the data to improve safety, not use it for "evil."

(from Streetsblog)

Want to automatically download the latest NYPD traffic crash data as a CSV instead of hard-to-interpret Excel file? Done!

Want to visualize collision data and break it down intersection by intersection? Done!

Installation

First, clone the repo:

git clone https://github.com/talos/nypd-crash-data-bandaid.git
cd nypd-crash-data-bandaid/

You'll need Python 2.7, and preferably virtualenv/virtualenvwrapper. Install the requirements in your virtualenv:

pip install -r requirements.txt

And run the shell script:

./bandaid.sh

You can even adapt the sample cronjob to run the script daily.

Hacking

There's lots'o'work to be done! Check out the TODO.

Credit

Thanks to David Turner for writing the original scrapeintersections.py script. It is accessible here.

Thanks to Matthew Kime for suggesting the name.

Thanks to Streetsblog for being awesome.

Thanks to Transportation Alternatives for supplying missing older data, the raw violations files, and the full list of violations URLs.

Thanks to Tom Swanson for his invaluable help in geocoding the vast majority of intersections. Check out his maps!

Just give me the data already!

OK, OK. Go to:

http://nypd.openscrape.com/

Historical data will be kept there, too. Watch the RSS feed!

I wanna API! I wanna make mashups!

Check out Crashmapper.

Data's there. I'm not stopping you. ;)

License

GPLv3, just as it should be.

About

nypd traffic crash data has a booboo. this eases the pain.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published