## 6 Results  
### Crash Likelihood Models  
The fitted RBLR crash likelihood model is summarized in Table 5. The explanatory variables that were significant at the 95% BCI included standard deviation of speed (Speed_sd_1015), average speed (speed_avg_1015), hourly precipitation (HourlyPrecipitation), hourly visibility (HourlyVisibility), and v/c ratio (v_ratio). As shown in the table, hourly precipitation, average speed, and standard deviation of speed have positive relationship with the crash occurrence (increase the odds of a crash outcome), while v/c ratio and hourly visibility have negative relationship with the crash occurrence (reduce the odds of a crash outcome). Application of the model with the testing dataset produced the AUC value of 0.67.  
\begin{table}
\begin{tabular}{c c c c} \hline \hline
**Variables** & **Mean** & **Std. Err** & **95\% BCI** \\ \hline speed\_sd\_1015 & 0.069 & 0.022 & (0.028, 0.111) \\ speed\_avg\_1015 & 0.32 & 0.024 & (0.415, 0.295) \\ HourlyPrecipitation & 0.125 & 0.033 & (0.082, 0.179) \\ HourlyVisibility & \(-\)0.118 & 0.026 & (\(-\)0.167, \(-\)0.071) \\ V\_ratio & \(-\)0.138 & 0.027 & (\(-\)0.192, \(-\)0.080) \\ Constant & \(-\)0.148 & 0.026 & (\(-\)0.206, 0.103) \\ \hline \hline \end{tabular}
\end{table}
Table 5: Summary of the Bayesian logistic regression model for crash likelihood.  
After the data preprocessing, the estimation of the RF, GBM, and KNN models involved hyperparameter tuning. The set of tuning parameters that were found to yield the highest AUC value for the RF, GBM, and KNN models are summarized in Table 6. The optimal hyperparameters in the RF model (mtry, split rule, and node size) were obtained using the OOB sample and 10-fold cross-validation. In the GBM model, several parameters were optimized as part of model tuning: number of trees (n.trees), the size of trees (interaction.depth), the learning rate (shrinkage), and the minimum number of observations allowed per node (n.minobisnnode). The tuning of the GBM is a challenging task considering the tradeoffs between model bias and variance. For example, allowing a larger number of trees improves the learning capability of the model, but it may lead to overfitting [35]. The larger size of trees increases the order of predictor-to-predictor interaction captured in the model [36], which increases the model and computation complexity that may not result in higher predictive power. The learning rate takes values between 0 and 1; generally, the lower learning rates provide better results by allowing more gradual \"climb\" in the regression combined with the larger number of trees in the model [37]. Finally, the minimum number of observations per node can be used to control the impact of 'noise' in the data on the model performance. Generally, increasing the minimum number of observations per node results in smaller trees that are less impacted by noise in the training data. Lastly, the K-parameter in the KNN model (i.e., the number of nearest neighbors considered in classification) was obtained in an iterative search process such that the selected K-value provided the highest accuracy of prediction based on the cross-validation of the training dataset.  
The performance indicators for the RBLR, RF, GBM, GNB, and KNN models, including the overall accuracy, sensitivity, specificity, and the AUC, are summarized in Table 6. The higher values for all metrics indicate better performance of the models, with the value if 1.00 indicating perfect (predictive) performance. The comparison shown in Table 6 indicates that the RF model outperforms all other models, followed by the RBLR and the GBM models.