Estimating the water quality index based on interpretable machine learning models

Water Sci Technol. 2024 Mar;89(5):1340-1356. doi: 10.2166/wst.2024.068.

Abstract

The water quality index (WQI) is an important tool for evaluating the water quality status of lakes. In this study, we used the WQI to evaluate the spatial water quality characteristics of Dianchi Lake. However, the WQI calculation is time-consuming, and machine learning models exhibit significant advantages in terms of timeliness and nonlinear data fitting. We used a machine learning model with optimized parameters to predict the WQI, and the light gradient boosting machine achieved good predictive performance. The machine learning model trained based on the entire Dianchi Lake water quality data achieved coefficient of determination (R2), mean square error, and mean absolute error values of 0.989, 0.228, and 0.298, respectively. In addition, we used the Shapley additive explanations (SHAP) method to interpret and analyse the machine learning model and identified the main water quality parameter that affects the WQI of Dianchi Lake as NH4+-N. Within the entire range of Dianchi Lake, the SHAP values of NH4+-N varied from -9 to 3. Thus, in future water environmental governance, it is necessary to focus on NH4+-N changes. These results can provide a reference for the treatment of lake water environments.

MeSH terms

  • Conservation of Natural Resources*
  • Environmental Policy*
  • Lakes
  • Machine Learning
  • Water Quality