Stroke risk prediction is challenging because stroke-positive cases are much fewer than non-stroke cases, making conventional accuracy-based evaluation potentially misleading. This study developed a machine learning pipeline for stroke risk prediction by combining genetic algorithm-based feature selection, calibrated XGBoost classification, threshold adjustment, decision curve analysis, and SHAP-based interpretation. A publicly available dataset containing 5,110 patient records was used. After preprocessing and feature selection, the final XGBoost model with isotonic calibration achieved ROC-AUC = 0.835, PR-AUC = 0.193, and Brier score = 0.0424. At the default threshold of 0.50, the model achieved high accuracy but failed to detect stroke-positive cases, with precision, recall, and F1-score all equal to 0.0000. Reducing the threshold to 0.15 improved recall to 0.5600 and F1-score to 0.3314, while the Youden-optimal threshold of 0.09 increased recall to 0.7400, although precision decreased to 0.1770. SHAP analysis showed that age was the only dominant explanatory feature retained after genetic algorithm-based feature selection. Higher age values shifted predictions toward the stroke-positive class, while lower age values reduced the predicted risk. These results indicate that the proposed pipeline improves interpretability and threshold-dependent analysis under class imbalance while exposing the trade-off between sensitivity and false-positive burden. However, the final model still depends heavily on age and should be viewed as a research-oriented decision-support framework rather than a ready-to-use clinical screening tool. Future studies should evaluate the pipeline using richer clinical variables and external validation datasets in independent clinical settings.
Copyrights © 2026