Optimization of Naive Bayes Algorithm Using Genetic Algorithm for Heart Failure Prediction
Teguh Cahyono(1*); Yogiek Indra Kurniawan(2); Bangun Wijayanto(3);
(1) Universitas Jenderal Soedirman
(2) Universitas Jenderal Soedirman
(3) Universitas Jenderal Soedirman
(*) Corresponding Author
AbstractFeature selection is often reported to improve clinical prediction, yet optimization and evaluation on the same data can produce optimistic estimates. This study provides a leakage-controlled and reproducible reassessment of genetic algorithm (GA) feature selection for Gaussian Naive Bayes prediction of heart disease. The open-Heart Failure Prediction dataset contains 918 observations, 11 predictors, and a binary target. Clinically implausible zero values in resting blood pressure and cholesterol were recoded as missing; imputation, scaling, one-hot encoding, GA selection, and model fitting were confined to training data. Performance was estimated using repeated nested stratified cross-validation with five outer folds repeated five times and four inner folds for GA fitness. The GA used an 11-bit chromosome, population size 12, 10 generations, 0.80 uniform-crossover probability, 0.08 bit-flip mutation probability, tournament selection of size three, and two elites. Across 25 held-out outer folds, baseline Naive Bayes achieved 84.66% accuracy (SD 2.01%), whereas GA-selected Naive Bayes achieved 84.31% (SD 2.40%). The paired mean difference was −0.35 percentage points, with a bootstrap 95% confidence interval of −0.72 to 0.05 percentage points and a Wilcoxon p-value of 0.120. AUC values were 0.912 and 0.907, respectively. The GA retained 8.44 of 11 predictors on average; ExerciseAngina, FastingBS, ST_Slope, and Sex were selected in every outer fold. These results do not support a material accuracy gain from GA selection, but demonstrate modest dimensionality reduction and reveal predictors that are stable under resampling. The study emphasizes nested evaluation, uncertainty reporting, and full parameter disclosure for credible optimization claims KeywordsHeart Disease Prediction; Naive Bayes; Genetic Algorithm; Feature Selection; Nested Cross-Validation; Reproducibility
|
Full Text:PDF |
Article MetricsAbstract view: 0 timesPDF view: 0 times |
Digital Object Identifier https://doi.org/10.33096/ilkom.v18i2.3559.420-429
|
Cite |
References
H. Azis, P. Purnawansyah, F. Fattah, I. P. Putri, “Performa Klasifikasi K-NN dan Cross Validation Pada Data Pasien Pengidap Penyakit Jantung,” ILKOM Jurnal Ilmiah, vol. 12, no. 2, pp. 81-86, 2020. doi: 10.33096/ilkom.v12i2.507.81-86
M. A. Islam, M. Z. H. Majumder, M. S. Miah, S. Jannaty, “Precision healthcare: A deep dive into machine learning algorithms and feature selection strategies for accurate heart disease prediction,” Computers in Biology and Medicine, vol. 176, pp. 108432, 2024. doi: 10.1016/j.compbiomed.2024.108432
Z. Noroozi, A. Orooji, L. Erfannia, “Analyzing the impact of feature selection methods on machine learning algorithms for heart disease prediction,” Scientific Reports, vol. 13, no. 1, pp. 22588, 2023. doi: 10.1038/s41598-023-49962-w
C. M. Bhatt, P. Patel, T. Ghetia, P. L. Mazzeo, “Effective Heart Disease Prediction Using Machine Learning Techniques,” Algorithms, vol. 16, no. 2, pp. 88, 2023. doi: 10.3390/a16020088
G. N. Ahmad, H. Fatima, S. Ullah, A. Salah Saidi, et al., “Efficient Medical Diagnosis of Human Heart Diseases Using Machine Learning Techniques With and Without GridSearchCV,” IEEE Access, vol. 10, pp. 80151-80173, 2022. doi: 10.1109/access.2022.3165792
A. Ogunpola, F. Saeed, S. Basurra, A. M. Albarrak, et al., “Machine Learning-Based Predictive Models for Detection of Cardiovascular Diseases,” Diagnostics, vol. 14, no. 2, pp. 144, 2024. doi: 10.3390/diagnostics14020144
N. Chandrasekhar, S. Peddakrishna, “Enhancing Heart Disease Prediction Accuracy through Machine Learning Techniques and Optimization,” Processes, vol. 11, no. 4, pp. 1210, 2023. doi: 10.3390/pr11041210
A. Saboor, M. Usman, S. Ali, A. Samad, et al., “A Method for Improving Prediction of Human Heart Disease Using Machine Learning Algorithms,” Mobile Information Systems, vol. 2022, pp. 1-9, 2022. doi: 10.1155/2022/1410169
I. M. El-Hasnony, O. M. Elzeki, A. Alshehri, H. Salem, “Multi-Label Active Learning-Based Machine Learning Model for Heart Disease Prediction,” Sensors, vol. 22, no. 3, pp. 1184, 2022. doi: 10.3390/s22031184
M. M. Ali, B. K. Paul, K. Ahmed, F. M. Bui, et al., “Heart disease prediction using supervised machine learning algorithms: Performance analysis and comparison,” Computers in Biology and Medicine, vol. 136, pp. 104672, 2021. doi: 10.1016/j.compbiomed.2021.104672
D. Bertsimas, L. Mingardi, B. Stellato, “Machine Learning for Real-Time Heart Disease Prediction,” IEEE Journal of Biomedical and Health Informatics, vol. 25, no. 9, pp. 3627-3637, 2021. doi: 10.1109/jbhi.2021.3066347
K. V. V. Reddy, I. Elamvazuthi, A. A. Aziz, S. Paramasivam, et al., “Heart Disease Risk Prediction Using Machine Learning Classifiers with Attribute Evaluators,” Applied Sciences, vol. 11, no. 18, pp. 8352, 2021. doi: 10.3390/app11188352
R. Katarya, S. K. Meena, “Machine Learning Techniques for Heart Disease Prediction: A Comparative Study and Analysis,” Health and Technology, vol. 11, no. 1, pp. 87-97, 2021. doi: 10.1007/s12553-020-00505-7
D. Shah, S. Patel, S. K. Bharti, “Heart Disease Prediction using Machine Learning Techniques,” SN Computer Science, vol. 1, no. 6, pp. 345, 2020. doi: 10.1007/s42979-020-00365-y
A. K. Gárate-Escamila, A. Hajjam El Hassani, E. Andrès, “Classification models for heart disease prediction using feature selection and PCA,” Informatics in Medicine Unlocked, vol. 19, pp. 100330, 2020. doi: 10.1016/j.imu.2020.100330
P. Ghosh, S. Azam, M. Jonkman, A. Karim, et al., “Efficient Prediction of Cardiovascular Disease Using Machine Learning Algorithms With Relief and LASSO Feature Selection Techniques,” IEEE Access, vol. 9, pp. 19304-19326, 2021. doi: 10.1109/access.2021.3053759
J. P. Li, A. U. Haq, S. U. Din, J. Khan, et al., “Heart Disease Identification Method Using Machine Learning Classification in E-Healthcare,” IEEE Access, vol. 8, pp. 107562-107582, 2020. doi: 10.1109/access.2020.3001149
F. Ali, S. El-Sappagh, S. R. Islam, D. Kwak, et al., “A smart healthcare monitoring system for heart disease prediction based on ensemble deep learning and feature fusion,” Information Fusion, vol. 63, pp. 208-222, 2020. doi: 10.1016/j.inffus.2020.06.008
W. DeGroat, H. Abdelhalim, K. Patel, D. Mendhe, et al., “Discovering biomarkers associated and predicting cardiovascular disease with high accuracy using a novel nexus of machine learning techniques for precision medicine,” Scientific Reports, vol. 14, no. 1, pp. 1, 2024. doi: 10.1038/s41598-023-50600-8
P. Agrawal, H. F. Abutarboush, T. Ganesh, A. W. Mohamed, “Metaheuristic Algorithms on Feature Selection: A Survey of One Decade of Research (2009-2019),” IEEE Access, vol. 9, pp. 26766-26791, 2021. doi: 10.1109/access.2021.3056407
M. Rostami, K. Berahmand, S. Forouzandeh, “A novel community detection based genetic algorithm for feature selection,” Journal of Big Data, vol. 8, no. 1, pp. 2, 2021. doi: 10.1186/s40537-020-00398-3
E. Ileberi, Y. Sun, Z. Wang, “A machine learning based credit card fraud detection using the GA algorithm for feature selection,” Journal of Big Data, vol. 9, no. 1, pp. 24, 2022. doi: 10.1186/s40537-022-00573-8
K. Rajwar, K. Deep, S. Das, “An exhaustive review of the metaheuristic algorithms for search and optimization: taxonomy, applications, and open challenges,” Artificial Intelligence Review, vol. 56, no. 11, pp. 13187-13257, 2023. doi: 10.1007/s10462-023-10470-y
B. F. Azevedo, A. M. A. C. Rocha, A. I. Pereira, “Hybrid approaches to optimization and machine learning methods: a systematic literature review,” Machine Learning, vol. 113, no. 7, pp. 4055-4097, 2024. doi: 10.1007/s10994-023-06467-x
Z. M. Elgamal, N. B. M. Yasin, M. Tubishat, M. Alswaitti, et al., “An Improved Harris Hawks Optimization Algorithm With Simulated Annealing for Feature Selection in the Medical Field,” IEEE Access, vol. 8, pp. 186638-186652, 2020. doi: 10.1109/access.2020.3029728
D. S. A. Elminaam, A. Nabil, S. A. Ibraheem, E. H. Houssein, “An Efficient Marine Predators Algorithm for Feature Selection,” IEEE Access, vol. 9, pp. 60136-60153, 2021. doi: 10.1109/access.2021.3073261
M. Tubishat, M. Alswaitti, S. Mirjalili, M. A. Al-Garadi, et al., “Dynamic Butterfly Optimization Algorithm for Feature Selection,” IEEE Access, vol. 8, pp. 194303-194314, 2020. doi: 10.1109/access.2020.3033757
T. Bhattacharyya, B. Chatterjee, P. K. Singh, J. H. Yoon, et al., “Mayfly in Harmony: A New Hybrid Meta-Heuristic Feature Selection Algorithm,” IEEE Access, vol. 8, pp. 195929-195945, 2020. doi: 10.1109/access.2020.3031718
H. Elmannai, N. El-Rashidy, I. Mashal, M. A. Alohali, et al., “Polycystic Ovary Syndrome Detection Machine Learning Model Based on Optimized Feature Selection and Explainable Artificial Intelligence,” Diagnostics, vol. 13, no. 8, pp. 1506, 2023. doi: 10.3390/diagnostics13081506
A. A. Alhussan, A. A. Abdelhamid, E. S. M. El-Kenawy, A. Ibrahim, et al., “A Binary Waterwheel Plant Optimization Algorithm for Feature Selection,” IEEE Access, vol. 11, pp. 94227-94251, 2023. doi: 10.1109/access.2023.3312022
, J. Amann, A. Blasimme, E. Vayena, et al., “Explainability for artificial intelligence in healthcare: a multidisciplinary perspective,” BMC Medical Informatics and Decision Making, vol. 20, no. 1, pp. 310, 2020. doi: 10.1186/s12911-020-01332-6
E. Tjoa, C. Guan, “A Survey on Explainable Artificial Intelligence (XAI): Toward Medical XAI,” IEEE Transactions on Neural Networks and Learning Systems, vol. 32, no. 11, pp. 4793-4813, 2021. doi: 10.1109/tnnls.2020.3027314
M. Roberts, D. Driggs, M. Thorpe, J. Gilbey, et al., “Common pitfalls and recommendations for using machine learning to detect and prognosticate for COVID-19 using chest radiographs and CT scans,” Nature Machine Intelligence, vol. 3, no. 3, pp. 199-217, 2021. doi: 10.1038/s42256-021-00307-0
F. Cabitza, A. Campagner, F. Soares, L. García de Guadiana-Romualdo, et al., “The importance of being external. methodological insights for the external validation of machine learning models in medicine,” Computer Methods and Programs in Biomedicine, vol. 208, pp. 106288, 2021. doi: 10.1016/j.cmpb.2021.106288
A. Bailly, C. Blanc, É. Francis, T. Guillotin, et al., “Effects of dataset size and interactions on the prediction performance of logistic regression and deep learning models,” Computer Methods and Programs in Biomedicine, vol. 213, pp. 106504, 2022. doi: 10.1016/j.cmpb.2021.106504
O. Rainio, J. Teuho, R. Klén, “Evaluation metrics and statistical tests for machine learning,” Scientific Reports, vol. 14, no. 1, pp. 6086, 2024. doi: 10.1038/s41598-024-56706-x
G. S. Collins, K. G. M. Moons, P. Dhiman, R. D. Riley, et al., “TRIPOD+AI statement: updated guidance for reporting clinical prediction models that use regression or machine learning methods,” BMJ, pp. e078378, 2024. doi: 10.1136/bmj-2023-078378
K. Lekadir, A. F. Frangi, A. R. Porras, B. Glocker, et al., “FUTURE-AI: international consensus guideline for trustworthy and deployable artificial intelligence in healthcare,” BMJ, vol. 388, pp. e081554, 2025. doi: 10.1136/bmj-2024-081554
M. Rosenblatt, L. Tejavibulya, R. Jiang, S. Noble, et al., “Data leakage inflates prediction performance in connectome-based machine learning models,” Nature Communications, vol. 15, no. 1, pp. 1829, 2024. doi: 10.1038/s41467-024-46150-w
D. Krstajic, L. J. Buturovic, D. E. Leahy, S. Thomas, “Cross-validation pitfalls when selecting and assessing regression and classification models,” Journal of Cheminformatics, vol. 6, no. 1, pp. 10, 2014. doi: 10.1186/1758-2946-6-10
A. Demircioğlu, “Measuring the bias of incorrect application of feature selection when using cross-validation in radiomics,” Insights into Imaging, vol. 12, no. 1, pp. 172, 2021. doi: 10.1186/s13244-021-01115-1
H. Azis, “Assessing the Performance of Logistic Regression in Heart Disease Detection through 5-Fold Cross-Validation,” International Journal of Artificial Intelligence in Medical Issues, vol. 2, no. 1, pp. 1-11, 2024. doi: 10.56705/ijaimi.v2i1.137
H. Azis, M. Abdullah, S. Ismail, “Performance Comparison of Various Weight and Combination Function on Heterogeneous Parallel Ensemble Machine Learning Model,” Journal of Advanced Research in Applied Sciences and Engineering Technology, vol. 56, no. 4, pp. 342-353, 2025. doi: 10.37934/araset.56.4.342353
Refbacks
- There are currently no refbacks.
Copyright (c) 2026 Teguh Cahyono, Yogiek Indra Kurniawan, Bangun Wijayanto

This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.






