Comparative Analysis of XGBoost and Random Forest Algorithms for Early Detection of Chronic Kidney Disease

Chronic kidney disease (CKD) often progresses without symptoms, so many patients are diagnosed late. This study compared Random Forest (RF) and Extreme Gradient Boosting (XGBoost) for early CKD detection under a single leakage-controlled protocol. The UCI CKD dataset (400 patients, 24 attributes) was processed in a pipeline in which imputation, encoding and SMOTE oversampling were fitted only on training folds, and both models were tuned with nested stratified cross-validation. Accuracy, precision, recall, F1-score, AUC, Matthews correlation coefficient and training time were measured, and the models were compared with the Wilcoxon and McNemar tests. SHAP values were used to explain the predictions. XGBoost achieved a mean accuracy of 98.50%, an F1-score of 98.80% and an AUC of 0.998, compared with 97.25%, 97.81% and 0.994 for RF, and it trained about 2.3 times faster. However, the difference was not statistically significant (p = 0.109). Haemoglobin, specific gravity, serum creatinine and albumin were the most influential predictors, and a reduced five-attribute model retained an accuracy of 97.75%. Both ensembles were therefore suitable for low-cost CKD screening in primary health care.

Authors

Publication Details

Journal
Journal of Information Technology computer science and Electrical Engineering
Published
2026-11-18
DOI
https://doi.org/10.61306/j0ke2t52
Primary Topic
Artificial Intelligence in Healthcare
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
NOV
article

Comparative Analysis of XGBoost and Random Forest Algorithms for Early Detection of Chronic Kidney Disease

Siti Rahmawati, Andi Pratama
Journal of Information Technology computer science and Electrical Engineering
Artificial Intelligence in Healthcare
article

Comparative Analysis of XGBoost and Random Forest Algorithms for Early Detection of Chronic Kidney Disease

Siti Rahmawati, Andi Pratama
article en

Abstract

Chronic kidney disease (CKD) often progresses without symptoms, so many patients are diagnosed late. This study compared Random Forest (RF) and Extreme Gradient Boosting (XGBoost) for early CKD detection under a single leakage-controlled protocol. The UCI CKD dataset (400 patients, 24 attributes) was processed in a pipeline in which imputation, encoding and SMOTE oversampling were fitted only on training folds, and both models were tuned with nested stratified cross-validation. Accuracy, precision, recall, F1-score, AUC, Matthews correlation coefficient and training time were measured, and the models were compared with the Wilcoxon and McNemar tests. SHAP values were used to explain the predictions. XGBoost achieved a mean accuracy of 98.50%, an F1-score of 98.80% and an AUC of 0.998, compared with 97.25%, 97.81% and 0.994 for RF, and it trained about 2.3 times faster. However, the difference was not statistically significant (p = 0.109). Haemoglobin, specific gravity, serum creatinine and albumin were the most influential predictors, and a reduced five-attribute model retained an accuracy of 97.75%. Both ensembles were therefore suitable for low-cost CKD screening in primary health care.

Journal of Information Technology computer science and Electrical Engineering
Artificial Intelligence in Healthcare
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon