# Risk and Pattern Analysis of Pakistani Crime Data Using Unsupervised Learning Techniques
###### Abstract
According to the Pakistan Bureau of Statistics report, it can be seen that the crime rate in Pakistan is increasing at a very high pace. The proposed work is an initiative to help the concerned agencies in the detection and prevention of criminal activities using exploratory data mining techniques. The availability of crime-related data is limited. Thus, in this research, actual crime-related data are gathered from different police stations in Lahore, Pakistan with the intent of \begin{table}
\begin{tabular}{c c c c c c c c c c} \hline \hline  & & & & \multicolumn{4}{c}{**Provinces/States**} & & & **Overall, in** \\ \cline{2-10}  & **Punjab** & **Sindh** & **KPK** & **Baluchistan** & **Islamabad** & **Railways** & **G. B** & **AJK** & **Pakistan** \\ \hline
**Murder** & 3914 & 1409 & 2361 & 325 & 84 & 6 & 61 & 75 & 8235 \\ Attempt to & 4440 & 1644 & 2641 & 333 & 163 & 5 & 94 & 179 & 9499 \\ \multicolumn{1}{c}{\begin{tabular}{c} Kidnapping/ \\ Abduction \\ \end{tabular} } & 13,558 & 2927 & 1197 & 248 & 99 & 7 & 48 & 279 & 18,363 \\ \multicolumn{1}{c}{\begin{tabular}{c} Dacotiy \\ Robbery \\ \end{tabular} } & 602 & 572 & 45 & 38 & 16 & 1 & 4 & 2 & 1280 \\ \multicolumn{1}{c}{\begin{tabular}{c} Robbery \\ \end{tabular} } & 9385 & 2364 & 276 & 185 & 195 & 4 & 15 & 34 & 12,458 \\ \multicolumn{1}{c}{\begin{tabular}{c} Burglary \\ \end{tabular} } & 11,023 & 1344 & 798 & 135 & 253 & 1 & 63 & 216 & 13,833 \\ \multicolumn{1}{c}{\begin{tabular}{c} Cattle Theft \\ \end{tabular} } & 4721 & 383 & 126 & 39 & 22 & 0 & 17 & 34 & 5342 \\ \multicolumn{1}{c}{\begin{tabular}{c} Other Theft \\ \end{tabular} } & 33,053 & 2221 & 882 & 272 & 506 & 234 & 64 & 72 & 37,304 \\ \multicolumn{1}{c}{\
\begin{tabular}{c} Others \\ Total \\ \end{tabular} } & 325,149 & 57,409 & 172,504 & 7917 & 5798 & 1270 & 1370 & 6194 & 577,611 \\ \multicolumn{1}{c}{
\begin{tabular}{c} Recorded \\ Crimes \\ \end{tabular} } & **405,845** & **70,273** & **180,830** & **9492** & **7136** & **1528** & **1736** & **7085** & **683,925** \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Crimes reported by the Pakistan Bureau of Statistics in the year 2017 (Crimes reported by the Pakistan Bureau of Statistics: [[https://bit.ly/3](https://bit.ly/3) fqgZJq]([https://bit.ly/3](https://bit.ly/3) fqgZJq) (accessed on 30 October 2020). reducing the crime rate in the concerned areas. In this study, the First Information Reports (FIR) data are initially collected in a complex format written in the Urdu language. The data of the FIRs are gathered from three different police stations in 'Mustafa town', 'Johar Town', and 'Mughalpura' areas of Lahore, Pakistan. The collected data of the FIRs are converted into the English language for attribute creation and feature selection. After completing the data pre-processing phase, the structured dataset has consisted of 24 attributes in total. The attribute selection is performed on the dataset to choose only those attributes that can help perform the cluster analysis and frequent pattern mining. The finalised dataset taken into consideration for the exploratory analysis has 636 records and six attributes in total [2017-2018]. Data visualisation analysis is applied to the finalised crime dataset to analyse the overall structure and trends present in the dataset. After getting insights from the data, data mining techniques named cluster analysis and association rule mining are applied to the crime dataset for exploratory analysis. In this research, we have proposed an interdisciplinary strategy between computer science and criminal justice to discover crime patterns using data mining techniques that can assist the concerned officers in fixing and solving offences more quickly. Data mining methods have flourished to predict the cyber-crimes in banking sectors [5], threat analysis and prediction [6], and cyber-crime analysis in social media [7]. For the identification of similar crime characteristics and risky areas, the k-modes clustering algorithm is applied.