Background: Public health datasets with rare outcomes require evaluation methods that show how well models identify the cases of interest. This study presents a leakage-controlled and explainable machine-learning workflow for classifying the stroke label in a public dataset. Methods: We analysed 5,110 records from the Kaggle Healthcare Stroke Dataset. After a stratified 80:20 split, four classifiers were compared through five-fold stratified cross-validation within the training partition. Imputation, scaling, encoding, and resampling were fitted within training folds. Three XGBoost imbalance strategies were evaluated, and the selected pipeline was assessed on the untouched 1,022-record test partition. SHAP explanations and a separate rule-based patient segment were integrated into a Streamlit prototype. Results: Stroke-label prevalence was 4.87%, and 201 records had missing BMI. Class-weighted XGBoost without SMOTE achieved the strongest combined cross-validated ROC-AUC (0.8459), PR-AUC (0.2206), F1 score (0.2560), and balanced accuracy (0.7792); logistic regression had marginally higher mean recall. On the test set, XGBoost achieved ROC-AUC 0.8458 and detected 41 of 50 positive records (recall 82.00%), while producing 219 false-positive flags (precision 15.77%). The comparison also showed that the tested class-weighting strategy gave a stronger overall metric profile than the tested resampling alternatives. Conclusion: The study offers a reproducible applied example of how leakage control, imbalance handling, threshold interpretation, explainability, and prototype integration can be evaluated together. Its findings provide a useful methodological reference for future work on rare health outcomes, while the dataset and internal evaluation define the scope of the conclusions.
Biswas, N., Uddin, K. M. M., Rikta, S. T., & Dey, S. K. (2022). A comparative analysis of machine learning classifiers for stroke prediction: A predictive analytics approach. Healthcare Analytics, 2, 100116. https://doi.org/10.1016/j.health.2022.100116
Brier, G. W. (1950). Verification of forecasts expressed in terms of probability. Monthly Weather Review, 78(1), 1–3. https://doi.org/10.1175/1520-0493(1950)078<0001:VOFEIT>2.0.CO;2
Chawla, N. V., Bowyer, K. W., Hall, L. O., & Kegelmeyer, W. P. (2002). SMOTE: Synthetic minority over-sampling technique. Journal of Artificial Intelligence Research, 16, 321–357. https://doi.org/10.1613/jair.953
Chen, T., & Guestrin, C. (2016). XGBoost: A scalable tree boosting system. In Proceedings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining (pp. 785–794). https://doi.org/10.1145/2939672.2939785
Collins, G. S., Moons, K. G. M., Dhiman, P., Riley, R. D., Beam, A. L., Van Calster, B., Ghassemi, M., Liu, X., Reitsma, J. B., van Smeden, M., Boulesteix, A.-L., Camaradou, J. C., Celi, L. A., Denaxas, S., Denniston, A. K., Glocker, B., Golub, R. M., Harvey, H., Heinze, G., ... Logullo, P. (2024). TRIPOD+AI statement: Updated guidance for reporting clinical prediction models that use regression or machine learning methods. BMJ, 385, e078378. https://doi.org/10.1136/bmj-2023-078378
Dritsas, E., & Trigka, M. (2022). Stroke risk prediction with machine learning techniques. Sensors, 22(13), 4670. https://doi.org/10.3390/s22134670
Fedesoriano. (n.d.). Stroke prediction dataset [Data set]. Kaggle. https://www.kaggle.com/datasets/fedesoriano/stroke-prediction-dataset
Kaufman, S., Rosset, S., Perlich, C., & Stitelman, O. (2012). Leakage in data mining: Formulation, detection, and avoidance. ACM Transactions on Knowledge Discovery from Data, 6(4), Article 15. https://doi.org/10.1145/2382577.2382579
Khan, M. A., Alsulami, M., Yaqoob, M. M., Alsadie, D., Saudagar, A. K. J., AlKhathami, M., & Khattak, U. F. (2023). Asynchronous federated learning for improved cardiovascular disease prediction using artificial intelligence. Diagnostics, 13(14), 2340. https://doi.org/10.3390/diagnostics13142340
Lundberg, S. M., & Lee, S.-I. (2017). A unified approach to interpreting model predictions. Advances in Neural Information Processing Systems, 30.
Sailasya, G., & Kumari, G. L. A. (2021). Analyzing the performance of stroke prediction using ML classification algorithms. International Journal of Advanced Computer Science and Applications, 12(6), 539–545. https://doi.org/10.14569/IJACSA.2021.0120662
Saito, T., & Rehmsmeier, M. (2015). The precision-recall plot is more informative than the ROC plot when evaluating binary classifiers on imbalanced datasets. PLOS ONE, 10(3), e0118432. https://doi.org/10.1371/journal.pone.0118432
Tazin, T., Alam, M. N., Dola, N. N., Bari, M. S., Bourouis, S., & Khan, M. M. (2021). Stroke disease detection and prediction using robust learning approaches. Journal of Healthcare Engineering, 2021, 7633381. https://doi.org/10.1155/2021/7633381
Tin, T. T., Wong, J. Q., Ali, A., Salau, A. O., Ikumapayi, O. M., & Afolalu, S. A. (2025). Towards the hybrid approach for predicting stroke risk: A feature augmented model. International Journal of Advanced Computer Science and Applications, 16(9). https://doi.org/10.14569/IJACSA.2025.0160993
World Health Organization. (2025, December 19). Stroke. https://www.who.int/news-room/fact-sheets/detail/stroke
Van Calster, B., McLernon, D. J., van Smeden, M., Wynants, L., & Steyerberg, E. W. (2019). Calibration: The Achilles heel of predictive analytics. BMC Medicine, 17, Article 230. https://doi.org/10.1186/s12916-019-1466-7
Ramakrishnan, T., Ghani, A., & Mahbob, N. N. (2026). Explainable Artificial Intelligence in Stroke Risk Prediction: Advancing Evidence-Based Healthcare Decision-Making. International Journal of Academic Research in Business and Social Sciences, 16(4), 1636–1660.
Copyright: © 2026 The Author(s)
Published by Knowledge Words Publications (www.kwpublications.com)
This article is published under the Creative Commons Attribution (CC BY 4.0) license. Anyone may reproduce, distribute, translate and create derivative works of this article (for both commercial and non-commercial purposes), subject to full attribution to the original publication and authors. The full terms of this license may be seen at: http://creativecommons.org/licences/by/4.0/legalcode