Stunting remains a major health concern in Indonesia due to its impact on children’s physical growth and cognitive development. One of the factors influencing the incidence of stunting is family economic status, which is linked to access to nutrition, sanitation, and a healthy environment. This study aims to optimize the performance of the XGBoost and Random Forest algorithms in classifying stunting in children based on economic factors and to compare the performance of the two models. The methods used in this study involve a machine learning approach, including data preprocessing, model training, hyperparameter optimization, and performance evaluation using a confusion matrix, accuracy, precision, recall, F1-score, and ROC-AUC curves. The results indicate that both algorithms perform well in classification, with an accuracy rate of approximately 70%. The Random Forest model demonstrated better performance than XGBoost with an AUC value of 0.7655, while XGBoost had an AUC value of 0.75. Additionally, the feature importance results indicated that economic and environmental factors, such as housing conditions and sanitation, have a significant influence on the incidence of stunting.
Copyrights © 2026