Skip to content

Flatiron School Data Science Phase 3 Classification Project - Seattle Police Department Terry Stop Arrest Classifier

License

Notifications You must be signed in to change notification settings

QiCai1995/Terry_Stop_Arrest_Predictor

Repository files navigation

Terry Stop Arrest Predictor

Project Overview

Key Business Problem

Build a classifier to predict whether an arrest was made after a Terry Stop, given information about the presence of weapons, the time of day of the call, etc. This is a binary classification problem.

Stakeholders

Civil rights organizations: people who work to protect civil liberties and ensure fair treatment of individuals by law enforcement. They can use this classifier’s predictions to highlight potential biases or disproportionate targeting during the Terry Stops.

Law enforcement agencies: police departments, law enforcement agencies, particularly street crime units, and the narcotics units that are responsible for conducting Terry Stops. They could use the predictions to evaluate the effectiveness of their practices and identify areas for improvement in terms of increasing successful arrests or reducing false positives.

The general public: Anyone who is interested in civil rights and law enforcement practices. It could contribute to public discourse on policing methods and their impact on communities.

Data Scientists who are interested in working in law enforcement agencies.

Data Understanding and Analysis

The overall goal is to come up with a binary classification model solution and to provide the top 2 features in this model.

Source of data

Terry Stops City of Seattle Open Data Portal

Description of Data: This data represents records of police-reported stops under Terry v. Ohio, 392 U.S. 1 (1968). Each row represents a unique stop. Each record contains the perceived demographics of the subject, as reported by the officer making the stop, and officer demographics as reported to the Seattle Police Department, for employment purposes.

Visualizations (the same visualizations presented in the slides and notebook)

Stops Arrest Background

Stop Resolution

On-Site Physical Arrest Rate

Dummy Model Confusion Matrix

Dummy Model ROC Graph

Logistic Regression Model Confusion Matrix

Logistic Regression Confusion Matrix

Logistic Regression ROC Graph

Logistic Regression ROC Graph

Logistic Regression Model Classification Report

Decision Tree Model Confusion Matrix

Decision Tree Confusion Matrix

Decision Tree ROC Graph

Decision Tree ROC Graph

Decision Tree Model Classification Report

Conclusion

The decision Tree Classifier Model has the best performance to predict the arrest rate after a Terry stop. It yields an F1 score of 0.89.

The top features in this model are the arrest flag and frisk flag.

Further Improvement

To further improve my model, I will use gridsearchCV for hyperparameter tuning to run my models in order to get a better F1 score. I will also be looking into feature importance to see what are the important features of my model. Also, applying other models, such as random forest, K-nearest neighbor.

About

Flatiron School Data Science Phase 3 Classification Project - Seattle Police Department Terry Stop Arrest Classifier

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published