DOI: 10.1093/eurheartj/ehag785.3887 ISSN: 0195-668X

Prediction and personalized interpretation of risk for multiple cancer outcomes in patients with heart failure: a machine learning study

Y Qi, Q Ren, C Wang, A Mastumoto, S Guo, G Chen, K Yiu

Abstract

Background

Patients with heart failure (HF) are at increased risk of incident cancer, and early identification of high-risk individuals could support timely clinical management and closer monitoring. However, accurate prediction across multiple cancer outcomes remains limited, particularly with models that can be readily interpreted at the individual patient level.

Objective

To develop machine learning models for predicting multiple cancer outcomes in patients with HF, and to provide personalized explanations of predicted risk.

Methods

We conducted a machine learning study using data from the Clinical Data Analysis and Reporting System (CDARS). Adults with HF were included and followed for incident cancer outcomes. We constructed separate binary prediction tasks for prostate cancer, lung cancer, colorectal cancer, gastric cancer, as well as overall incident cancer. Candidate predictors comprised 38 routinely available variables, including demographics, lifestyle factors, comorbidities, medications, and laboratory markers. The cohort was randomly split into training and internal validation sets (8:2). We trained XGBoost and addressed severe class imbalance using a class-weighted objective function. Predictive performance was evaluated using AUROC. Model interpretability was assessed using the SHAP method to quantify global feature contributions and to generate patient-specific explanations of predicted risk.

Results

In a total of 261,633 patients with HF in CDARS, 44,768 developed incident cancer during follow-up. The incident cancer cases comprised 2,771 prostate cancers, 5,532 lung cancers, 7,926 colonrectum cancers, and 1,721 gastric cancers. Across the five prediction tasks, the XGBoost models demonstrated good discrimination in held-out test sets. The AUROC was 0.825 (95% CI 0.808–0.840) for prostate cancer, 0.814 (95% CI 0.800–0.827) for lung cancer, 0.806 (95% CI 0.795–0.818) for colonrectum cancer, 0.780 (95% CI 0.754–0.805) for gastric cancer, and 0.795 (95% CI 0.789–0.801) for the all types of cancer outcome. Across all cancer prediction tasks, SHAP analyses consistently identified age as the dominant contributor to model predictions. Across the four cancer models, SHAP highlighted shared predictors (glucose/HbA1c, CRP, creatinine/eGFR, Hb/anemia, and lipids) but also cancer-type differences, with smoking most prominent for lung cancer and anemia/low hemoglobin particularly influential for colorectal cancer. In addition, the model can take an individual patient’s clinical profile as input to generate personalized risk estimates and patient-specific explanatory analyses.

Conclusion

​ We developed machine learning models that accurately predicted multiple incident cancer outcomes in this high-risk heart failure population. This study provides real-world evidence supporting explainable, patient-level cancer risk stratification , informing ndividualized management for patients with cardiometabolic multimorbidity.ROC and SHAP analysis

More from our Archive