Abstract:
Predicting water quality in a heterogeneous watershed is challenging because parameters and prediction accuracy vary with space. Therefore, spatially adaptive machine learning models were introduced for predicting water quality conditions in the Haraz and Babolroud watersheds, Iran. Initially, the Irrigated Water Quality Index (IWQI) was calculated. Then, spatial clusters of 16 water quality stations having similar physiochemical characteristics were identified. In the next step, numerical prediction models were developed for each cluster by assessing the prediction accuracy of six machine learning models including support vector machine (SVM), random forest (RF), extra trees (ET), extreme gradient boosting (XGBoost), decision trees (DT), and boosted regression trees (BRT). Finally, a sensitivity analysis was carried out to investigate the sets of key parameters needed to enhance water quality prediction using locally optimised prediction models. The findings indicated that water quality varied across the study area and three clusters, based on physico-chemical characteristics of the water quality, of the monitored stations were identified. The XGBoost model gave the highest accuracy and performance in cluster 1, 2, and 3 with R 2 values of 0.99 and RMSE values of 0.02, 0.05, and 0.02, respectively. The results indicated that acceptable local prediction can be obtained using different water quality parameters in the clusters across the watershed. Our findings can help managers and policymakers providing prompt alerts regarding irrigation water quality concerns in adaptive agricultural development.