Data Study on NYC Safety

Posted on Apr 28, 2019
The skills we demoed here can be learned through taking Data Science with Machine Learning bootcamp with NYC Data Science Academy.


Traffic collisions in New york city are all too common and can result in devastating injuries and death. Even so, New Yorkers and tourists travel around the city risking life and limb to get where they need to go. This R Shiny project is designed to give data insight in to when, where and how to best to travel around the five boroughs of New York, safely. 

Follow the following links to view my Shiny app and the code on Github.  

Data & Methodology

The dataset used for this app was provided by NYC Open Data and the NYPD. Every traffic collision that occurs in NYC where the police are called is recorded in to a database with associated data regarding location, time, persons and vehicles involved, and any injuries that occured. This data set has recorded collisions for 2015 through early 2017.

This app is designed to show trends in collisions as well as give the user the ability to filter for their specific neighborhoods, commuting path and time if desired. I filtered the data to involve only collisions with an injury or death having occurred.  This provided enough data points to spot trends in collisions as well as being more relevant for the user. 

In addition to the data that is provided by the NYPD, I added extra columns to break down the collisions in to:

  • Weekday and Weekend
  • Type of transportation
  • Dangerous or Deadly


The App and Data Results


The map provides the user the ability to view groupings and trends of collisions filtered by:

  • Weekday or Weekend
  • Transportation type
  • Time of day
  • Time of year
  • Number of collisions  

The last slider provides the user the ability to "declutter" the map and more easily spot overall trends. 

Data Study on NYC Safety

Some areas are hotbeds for collisions:

  • Midtown Manhattan
  • Bridge Entrances
  • Busy Transfer points (Subway entrances leading in to vehicle traffic)

Weekend collisions are much less prevalent than weekday.

Tables and Charts 

The "Tables and Charts" tab gives more insight in to more relative differences in time and location. 

Looking at collisions over the course of the day, "deadly" collisions are more clustered between the hours of 8PM and 6AM whereas "dangerous" collisions peak during morning and evening rush hour hour.   

The tables below the graph update with the user inputs and show the most frequent types of each variable. 

Many more insights and trends can be gleaned from the map, tables and plot by changing the variables and inputs. 


Future Research

I look to further my app and research in to NYC collisions by adding more interactivity to the map and looking at correlations between types of drivers, age of driver, and  seasonality. 

About Author

Aydan Ellman

Data Science Fellow and Cornell University graduate with demonstrated experience in business development and the application of data analysis to drive business performance.
View all posts by Aydan Ellman >

Related Articles

Leave a Comment

Google August 28, 2021
Google Always a big fan of linking to bloggers that I adore but really don't get a whole lot of link like from.
Google January 2, 2021
Google Although internet sites we backlink to beneath are considerably not associated to ours, we really feel they may be in fact worth a go as a result of, so have a look.
Google December 18, 2020
Google The time to study or pay a visit to the material or web-sites we've linked to beneath.
CBD Oil For Dogs December 18, 2020
CBD Oil For Dogs [...]check beneath, are some completely unrelated internet websites to ours, nevertheless, they're most trustworthy sources that we use[...]
RDP August 28, 2020
RDP [...]always a large fan of linking to bloggers that I appreciate but don’t get a good deal of link adore from[...]
Google August 21, 2020
Google One of our visitors lately advised the following website.
Google August 20, 2020
Google Usually posts some really exciting stuff like this. If you are new to this site. August 19, 2020 [...]one of our visitors not long ago recommended the following website[...] August 5, 2020 [...]below you’ll locate the link to some web-sites that we think you should visit[...] July 30, 2020 [...]usually posts some quite exciting stuff like this. If you are new to this site[...]
cbd oil for cats July 9, 2020
cbd oil for cats [...]always a significant fan of linking to bloggers that I really like but really don't get quite a bit of link enjoy from[...]

View Posts by Categories

Our Recent Popular Posts

View Posts by Tags

#python #trainwithnycdsa 2019 2020 Revenue 3-points agriculture air quality airbnb airline alcohol Alex Baransky algorithm alumni Alumni Interview Alumni Reviews Alumni Spotlight alumni story Alumnus ames dataset ames housing dataset apartment rent API Application artist aws bank loans beautiful soup Best Bootcamp Best Data Science 2019 Best Data Science Bootcamp Best Data Science Bootcamp 2020 Best Ranked Big Data Book Launch Book-Signing bootcamp Bootcamp Alumni Bootcamp Prep boston safety Bundles cake recipe California Cancer Research capstone car price Career Career Day citibike classic cars classpass clustering Coding Course Demo Course Report covid 19 credit credit card crime frequency crops D3.js data data analysis Data Analyst data analytics data for tripadvisor reviews data science Data Science Academy Data Science Bootcamp Data science jobs Data Science Reviews Data Scientist Data Scientist Jobs data visualization database Deep Learning Demo Day Discount disney dplyr drug data e-commerce economy employee employee burnout employer networking environment feature engineering Finance Financial Data Science fitness studio Flask flight delay gbm Get Hired ggplot2 googleVis H20 Hadoop hallmark holiday movie happiness healthcare frauds higgs boson Hiring hiring partner events Hiring Partners hotels housing housing data housing predictions housing price hy-vee Income Industry Experts Injuries Instructor Blog Instructor Interview insurance italki Job Job Placement Jobs Jon Krohn JP Morgan Chase Kaggle Kickstarter las vegas airport lasso regression Lead Data Scienctist Lead Data Scientist leaflet league linear regression Logistic Regression machine learning Maps market matplotlib Medical Research Meet the team meetup methal health miami beach movie music Napoli NBA netflix Networking neural network Neural networks New Courses NHL nlp NYC NYC Data Science nyc data science academy NYC Open Data nyc property NYCDSA NYCDSA Alumni Online Online Bootcamp Online Training Open Data painter pandas Part-time performance phoenix pollutants Portfolio Development precision measurement prediction Prework Programming public safety PwC python Python Data Analysis python machine learning python scrapy python web scraping python webscraping Python Workshop R R Data Analysis R language R Programming R Shiny r studio R Visualization R Workshop R-bloggers random forest Ranking recommendation recommendation system regression Remote remote data science bootcamp Scrapy scrapy visualization seaborn seafood type Selenium sentiment analysis sentiment classification Shiny Shiny Dashboard Spark Special Special Summer Sports statistics streaming Student Interview Student Showcase SVM Switchup Tableau teachers team team performance TensorFlow Testimonial tf-idf Top Data Science Bootcamp Top manufacturing companies Transfers tweets twitter videos visualization wallstreet wallstreetbets web scraping Weekend Course What to expect whiskey whiskeyadvocate wildfire word cloud word2vec XGBoost yelp youtube trending ZORI