NYC Shootings Analysis

Shootings have become a growing problem in the United States. As a NYC resident, I wanted to know what the shootings situation was like in my city. I found a dataset on NYC Open Data that has all the past reported shootings from 2005-2022, this was perfect for my goal.
Link to Dataset: Click Here
Questions to Answer
- How many total reported shootings in NYC from 2017-2022?
- 1.1 How many shootings in each borough?
- How many total shootings each year from 2017-2022
- 2.1 How many in each borough each year?
- Is there a monthly pattern in shootings?
- What is the deadliest shooting incident from 2017-2022?
- What is the distribution of shootings by each hour in 2022?
- What is the distribution of shootings by victim and perpetrator demographics in 2022?
- What are the top 5 precincts with the most shootings in 2022?
Approach
Data Cleaning/Transformatioin
- Loaded the dataset into a Pandas Dataframe in a Jupyter Notebook for data cleaning
- Checked for outlier values and nulls, all outlier values were fixed and null values were filled in
- Removed unnecessary columns and filtered out rows of data that were not needed for my analysis
- Changed the structure of the original dataset by splitting it into two separate CSV files that can be joined together
- Transformed the data by storing the CSV files in tables in a SQLite3 database
Link to Data Cleaning: Click Here
Analysis
- Peformed analysis using combination of SQL queries and Pandas dataframes
- Visualized queries using libraries like Matplotlib and Seaborn
Link to Analysis: Click Here
You can click below if you want to see the entire project repo on Github