Water quality is an important factor that affects human health and the environment. In Indonesia, access to consumable water is still limited, so a fast and accurate water quality classification method is needed. This study aims to develop a classification model based on Machine Learning using the Random Forest algorithm to predict the feasibility of drinking water. The dataset used is Water Quality from Kaggle with 3,276 data and 9 parameters. The preprocessing stage includes data cleaning, handling missing values using IterativeImputers, data sharing, and normalization using StandardScaler. The three algorithms were compared, namely Random Forest, Decision Tree, and Naïve Bayes. The results showed that Random Forest had the highest accuracy of 69%, higher than Decision Tree (64%) and Naïve Bayes (63%). However, the model had a performance imbalance with high Recall in the non-drinkable class (89%) and low in the drinkable class (38%). The feature importance analysis shows that Sulfate, pH, and Hardness are the most influential parameters. This study contributes through the use of a more optimal imputation method in improving classification performance.
Copyrights © 2026