__STYLES__

Traffic Safety Analysis - A Guided Maven Project

Tools used in this project
Traffic Safety Analysis - A Guided Maven Project

About this project

As a new member of the analytics taskforce of the NYC Police Department, the team had been tasked to analyze data with the purpose of finding interesting patterns and trends to help the NYPD prevent future accidents. The team had access to data on all traffic accidents in NYC from Jan 1st, 2021, up to April 9th, 2023. The three objectives include:

  1.  Identify seasonal patterns:
    

I calculated the number of collisions by month and year and visualized them using a line chart. I dropped the month of April 2023, as it did not give a total months’ worth of data and I didn’t want it to skew the rest of the data. The year lines followed a similar shape and pattern. There was a small drop between Jan and Feb, then an increase between Feb and March. They peaked between the months of May and June and then slightly decreased between July and September. Overall, 2021 showed a higher number of collisions than in 2022.

  1.  Visualize weekly trends:
    

I calculated the number of collisions by time of day and day of week and visualized the data using a heatmap. I extracted Weekday and Hour from the Date and Time columns of the data source. Weekday 1 starts on Monday, weekday 7 ends with Sunday. I used a “white-white-red” 3-color scale to focus on the most dangerous hours of the week. The heatmap showed that the most collisions occur during the commute hours of 8am Tues-Thurs, and between 3-4pm on Fridays. Collisions over the weekend were higher during the midnight hour.

  1.  Analyze contributing factors:
    

Lastly, I looked at finding the top 10 contributing factors by number of collisions and calculated the percentage of the collisions involving injuries or fatalities. I created a calculated field to look at the “% of Dangerous Collisions” which took each contributing factor involving an injury or fatality and divided them by the total number of collisions.

The top contributing factor of collisions was “Driver Inattention/Distraction”, with 39% of those instances being dangerous. The second contributing factor was “Unspecified”, which could mean input error or lack of information when the officer was taking down information at the collision scene. The third most contributing factor was “Failure to Yield Right-of-Way” and had the highest percentage of being dangerous at 64%.

Discussion and feedback(0 comments)
2000 characters remaining
Cookie SettingsWe use cookies to enhance your experience, analyze site traffic and deliver personalized content. Read our Privacy Policy.