Abstract
Heart disease presents significant challenges to healthcare systems globally, being the primary cause of death and disability. Timely and accurate diagnosis is crucial for effective disease management and prevention. However, traditional medical approaches often face issues like misdiagnoses and treatment delays, leading to higher costs and health complications for patients. Machine learning (ML) algorithms offer promising solutions by enhancing diagnostic accuracy and reducing errors. There is a growing interest in utilizing ML in healthcare, with ML methods playing a crucial role in analyzing medical data and assisting healthcare decisions despite facing challenges in accurate identification. In this study, we propose a novel approach to enhance heart disease detection using a stacked ensemble model integrating various ML techniques. Initially, we address data quality by identifying and removing outliers. Then, three feature selection methods (Pearson, Chi-Square Test, and Recursive Feature Elimination) are applied to improve model performance. The resulting stacked classifier model exhibits superior accuracy (93.3%), precision (91.9%), and F1 score (93.9%), demonstrating significant improvements over raw data. Additionally, we employ Shapley additive explanation (SHAP) values for interpretability, providing insights into feature importance. This study aims to advance heart disease diagnosis and contribute to better patient outcomes by integrating quantitative metrics and concise descriptions of the proposed solution.