Heart disease is one of leading causes of death globally, making early detection essential for improving clinical outcomes. This study presents a heart disease prediction approach using the K-Nearest Neighbor (KNN) algorithm, addressing class imbalance with Synthetic Minority Over-sampling Technique (SMOTE) and enhancing feature selection through Ant Colony Optimization (ACO). Exploratory data analysis identified age, gender, cholesterol, blood pressure, e xercise-Induced Angina (EIA), ST-segment depression, number of affected vessels, and thalassemia status as key indicators of disease severity. KNN model achieved 0.90 accuracy with balanced precision and recall. The employment of SMOTE improved sensitivity for the minority class, slightly reducing overall accuracy to 0.88. However, ACO as hyperparameter tuning KNN able to produce promising accuracy 0.91. This result indicate that combining KNN with metaheuristic optimization provides a reliable, interpretable method for heart disease prediction, offering valuable support for clinical decision-making and risk assessment.
Copyrights © 2026