This project analyzes Toronto's annual police budget and crime statistics from 2020 to 2023 using R. By examining the relationship between the police budget and total reported crimes, as well as changes in the crime clearance rate, the project aims to determine whether the resources allocated to the police department translate into effective crime prevention and enhanced safety for Toronto's citizens.
The repository is structured as:
data/raw_data
contains the raw data as obtained from Open Data Toronto and simulated data.data/analysis_data
contains the cleaned datasets and summary tables that were constructed.other
contains details about LLM chat interactions and sketches.paper
contains the files used to generate the paper, including the Quarto document and reference bibliography file, as well as the PDF of the paper. scripts
contains the R scripts used to simulate, download, clean data, test, and analyze the data.Aspects of the code in the scripts were written with the help of generative AI tool, ChatGPT. ChatGPT was also used to correct typos, spelling mistakes, and filler words for the paper. The entire chat history is available in inputs/llms/usage.txt.