Diabetes Detection Using Extreme Gradient Boosting (XGBoost) with Hyperparameter Tuning

  • Devi Aprilya Dinathi Universitas Muhammadiyah Malang
  • Elisa Ramadanti Universitas Muhammadiyah Malang
  • christian sri kusuma aditya Universitas Muhammadiyah Malang
  • Didih Rizki Chandranegara Universitas Muhammadiyah Malang
Keywords: Diabetes, XGBoost, SMOTE, Hyperparameter Tuning, GridSearchCV, RandomSearchCV


Diabetes is a metabolic disorder caused by problems with insulin production in the body. Diabetes is one of the deadliest diseases worldwide, especially in Indonesia. Diabetes can cause various serious complications to the sufferers and can lead to death. With current technological advances, machine learning algorithms can identify diabetes using available data for analysis. One of the machine learning methods that can be applied is Extreme Gradient Boosting (XGBoost). This study aims to find the best classification performance on diabetes datasets using the XGBoost method. The dataset used consists of 768 rows and 9 columns, with target values of 0 and 1. In this study, resampling is applied to overcome data imbalance using SMOTE and optimize hyperparameters using GridSearchCV and RandomSearchCV. Model evaluation is done using confusion matrix and various metrics such as accuracy, precision, recall, and f1-score. This research conducted several three test scenarios. The first test was hyperparameter optimization using GridSearchCV. The second test was hyperparameter optimization using RandomSearchCV. In the third test by applying data resampling, the XGBoost method achieved the highest accuracy of 82% with GridSearchCV hyperparameter optimization.


Download data is not yet available.
How to Cite
D. Aprilya Dinathi, E. Ramadanti, christian sri kusuma aditya, and D. R. Chandranegara, “Diabetes Detection Using Extreme Gradient Boosting (XGBoost) with Hyperparameter Tuning”, Indones.J.electronic.electromed.med.inf, vol. 6, no. 2, May 2024.
Research Article