# The Use of Machine Learning Methods in Road Safety Research in Poland
## 6 Conclusions  
In summary, it can be concluded that Random Forest (RF) is the best choice for handling imbalanced datasets, especially when identifying rare classes like \"severe injuries\" and \"deaths\" is the primary goal. For situations where achieving the highest overall accuracy is critical, k-Nearest Neighbors (KNN) provides a reasonable compromise. Meanwhile, RPart can serve as a fast baseline model but requires improvements to effectively manage rare classes.  
This research demonstrates that ML models have the potential to predict traffic hazards and their consequences. In the long term, these models could become valuable tools for managing road safety. However, there are still limitations, mainly related to the availability, collection and sharing of data, which significantly affect the performance of the proposed models. First of all, many minor collisions are not reported to the police, which means that the statistics may not include all events. Moreover, the data currently provided do not contain details on the traffic volume, weather conditions, quality of infrastructure or technical condition of vehicles. There is no doubt that factors such as atmospheric precipitation or parameters such as the road width, lane width or road surface condition may affect the number of road traffic incidents and their severity for participants. Another issue is the fact that the available statistics are based mainly on reports and notifications, which not only prevents full consideration of all aspects but may also cause inconsistencies related to data collection and even errors resulting from the human factor, e.g., incorrect description of the circumstances of the incident. This only shows that a transformation is necessary toward the use of advanced tools for monitoring road traffic incidents. Moreover, there is a lack of integration of available police statistics with other sources. Fully harnessing the potential of ML algorithms requires a unified system for collecting and sharing data on road incidents, traffic volumes and even weather conditions. Establishing such a system should be a priority for Polish policymakers aiming to improve road safety.  
Taking into account the obtained results, future research on the use of machine learning tools in the context of road safety in Poland should focus on developing models that, thanks to detailed and consistent data, will be able to predict road incidents and their consequences depending on the weather conditions, the traffic intensity or the condition and quality of the road infrastructure. Such ML models could not only help identify specific weather conditions conducive to accidents but also assess the importance of the condition of the road surface or geometry in the context of participant safety. Another reasonable direction for future research may be the development of spatial and temporal models based on ML that allow prediction of the place and time of increased risk of accidents. Integration with geographic data (GIS) could identify spatial patterns regarding the probability of road traffic events, along with their potential consequences. Ultimately, from a broader perspective, ML models could positively impact the overall road traffic safety in Poland by finding applications in designing safer road infrastructure, optimizing traffic management, and implementing changes to regulations, such as speed limits.  
Conceptualization, A.B.; methodology, A.B. and S.S.; formal analysis, A.B. and S.S.; data curation, A.B.; writing--original draft preparation, S.S.; writing--review and editing, A.B. and S.S.; visualization, S.S.; supervision, A.B. All authors have read and agreed to the published version of the manuscript.  
This research received no external funding.  
Not applicable.  
The raw data supporting the conclusions of this article will be made available by the authors on request.  
The authors declare no conflicts of interest.