Abstract
Crime prevention and detection are critical challenges for law enforcement globally. With increasing crime data and advancements in machine learning, predictive algorithms offer a promising solution. Maiduguri has experienced rising crime rates, yet lacks intelligent systems to aid security efforts. This study aims to model crime prevention and detection using predictive algorithms, specifically comparing Decision Trees (DT), Random Forest (RF), and Support Vector Machines (SVM). A quantitative approach was adopted, with data collected from Maiduguri security agencies and online sources. The algorithms were analyzed using Python, evaluating performance via accuracy, precision, recall, and F1-score. Results showed DT and RF excelled: DT achieved perfect scores (1.000) across all metrics, while RF scored highly (accuracy: 0.9950, precision: 0.9955, recall: 0.9950, F1-score: 0.9951). In contrast, SVM performed poorly (accuracy: 0.5075, precision: 0.5372, recall: 0.5075, F1-score: 0.4910), highlighting the importance of algorithm selection. Visualizations of crime frequency by location, time, and victim age distribution further aid law enforcement in resource allocation and targeted interventions. The study demonstrated that DT and RF are highly effective for crime prediction in Maiduguri, offering actionable insights for improving public safety. SVM’s limitations suggest it is less suitable for this task, emphasizing the need for appropriate algorithm choices in crime analytics.
Keywords: Crime, Detection, Machine learning, Model and Predictive algorithms.