# Utilizing Different Machine Learning Techniques to Examine Speeding Violations
## 3 Results  
Evaluating machine learning models and algorithms is crucial to any research or project. The quality of a statistical or machine-learning model is measured using evaluation metrics. To examine the classifiers' performance and specify the best one, the evaluation metrics were utilized to compare the classifiers' performance. Table 2 shows the four-evaluation metrics: accuracy, RMSE, Kappa statistic, and F-measure for the three classifiers. These values for RF, CART, and MLP are 86.42%, 81.16% and 73.02%, respectively. The RF achieved the highest accuracy value, while the lowest value was for the MLP algorithm. Figure 6 shows the accuracy values. The Kappa statistic measures how close the classified instances are to the true ones. An F-measure is used to measure the model's accuracy. Figure 7 shows the Kappa statistic, F-measure, and RMSE results. The Kappa statistic values for RF, CART, and MLP are 0.728, 0.623, and 0.46, respectively. The F-measure values for RF, CART, and MLP are 0.864, 0.811, and 0.73, respectively. Kappa statistic values for RF and CART are between 0.61 and0.8; substantial agreements, MLP Kappa statistic value is within the range (0.41-0.6); moderate agreement. F-measure values are high and indicate excellent accuracy. \begin{table}
\begin{tabular}{c c c c c} \hline
**Classifier** & **Accuracy\%** & **RMSE** & **Kappa Statistic** & **F-Measure** \\ \hline RF & 86.42 & 0.3245 & 0.728 & 0.864 \\ CART & 81.16 & 0.3972 & 0.623 & 0.811 \\ MLP & 73.02 & 0.43 & 0.46 & 0.73 \\ \hline \end{tabular}
\end{table} 
Table 2: Evaluation Metrics. RMSE showed the error in predicting the true values. The RMSE values for RF, CART, and MLP are 0.3245, 0.3972, and 0.43, respectively. RF achieved the lowest value, while MLP achieved the highest value. AUC indicated the ability of the model to distinguish between the classes. ROC showed the relationship between the true-positive rates (\(\gamma\)-axis) and false-positive rates (\(X\)-axis). Table 3 presents AUC and ROC values; the results show that all the AUC values for all classifiers are more than 0.5; the classifiers have a good ability to distinguish between the classes. Figure 6: Classifiers’ Accuracies. Figure 7: Kappa, F-measure, and RMES Results. to distinguish classes. RF has the highest values, which indicate excellent performance. Figure 8 shows the ROC curves for the classifiers. The approach of the curve from the top-left corner indicates the good performance of the algorithm. It is obvious that the RF curve is the closest one to the top-left corner (i.e., it gives the best performance). Based on the analysis results, the three classifiers showed good ability for classifying and predicting speeding violations, especially RF. The superior performance of the RF is  
Figure 8: ROC curves for the two classes: Yes (**left** figures), No (**right** figures). \begin{table}
\begin{tabular}{c c c c} \hline
**Classifier** & **Dependent Variable Classes** & **AUC Area** & **ROC Area** \\ \hline \multirow{3}{*}{CART} & Yes & 0.834 & 0.835 \\  & No & 0.834 & 0.835 \\  & Yes & 0.941 & 0.941 \\ \multirow{3}{*}{RF} & No & 0.941 & 0.941 \\  & Yes & 0.807 & 0.808 \\ \multirow{3}{*}{MLP} & No & 0.807 & 0.808 \\ \hline \end{tabular}
\end{table} 
Table 3: AUC and ROC results. due to its nature. Its result depends on the majority votes for several decision trees. RF uses the bagging technique, which depends on randomness for data selection. In addition to that, there is no association between the decision trees in RF, which increase the forest accuracy. Furthermore, RF does not need many calculations to build the model and can deal with missing values, unlike the MLP. Age, road alignment, speed limit, weather, and accident time were the most influential factors for speeding violations in this study. Age groups (\(\leq\)25) and (26-35) were associated with speeding violations; this result is matched with several previous studies [17; 20; 21].