Prediction of Abidjan Groundwater Quality Using Machine Learning Approaches: An Exploratory Study ()
1. Introduction
Worldwide, Groundwater quality presents urgent and complex challenges impacting the environment, health, and well-being of individuals in communities. Being a major source of fresh water, the quality of groundwater is essential for sustaining life, supporting ecosystems, and driving economic activities [1]. In Abidjan the capital of Côte d’Ivoire, Groundwater from the Continental Terminal (CT) accounts for about 68% of the total drinking water production [2]. Unfortunately, this resource quality is subject to continuous deterioration, as reported by the national water supply company [3]. The key reported causes of deterioration include the dispersion of solid and liquid waste materials, the sanitation equipment and system shortage, the improper disposal of used oils, and the discharge of non-compliant waste from households, industries, or automobile workshops [4]. Moreover, over 79% of the district’s groundwater shows unsafe hydrogeological protection, while 12% is vulnerable [5]. Developing nations like Côte d’Ivoire strive to raise and regulate water quality monitoring systems. However, Abidjan aquifers lack unified approaches and resource management policy as there are several decision-making centers with opposing stands [6]. Besides these issues, another challenge in groundwater quality monitoring is the complex and variable nature of the hydrogeological system, which can generate fuzziness in the assessment process [7]-[9]. Furthermore, water quality assessment generates an intricate database of various parameter types, often overlooked by most stakeholders. The primary interest of these assessments lies in the interpretation derived with a significantly heightened focus on the inferences drawn regarding the suitability of the water resources for different purposes (drinking, agriculture, or industry) [10] [11]. Consequently, setting up a detailed approach to offer insights into ground and surface water quality regarding their intended functions is important [12] as applied by the WQI. The Water quality index (WQI) defines the overall state of water bodies by converting concentrations of water quality parameters into a numerical score. This is achieved via calculation techniques [13], minimizing the significant amount of data in a single value and enabling their straightforward interpretation [14] [15]. The WQI is widely used to classify ground and surface water quality [16]-[18]. The applied WQI model comprises five key steps, including the selection of water quality parameters, the conversion of parameter values into dimensionless sub-indices or parameters standardization, the weight attribution to individual parameters, the aggregation of the weighting factors with standardized values to obtain the final WQI value, and the categorization of the resource quality based on the WQI classification ranges [19] [20].
The primary drawback is the variability of the conventional weight assignment to parameters in the WQI calculation [21] [22]. In contrast, multi-criteria decision analysis methods (MCDM), such as the analytical hierarchy process (AHP), represent a consistent weighting system that avoids misjudgments. AHP is a robust method for determining parameter weights through matrix comparisons that minimizes errors and improper weight distributions [20]. In water quality assessment, the need for large amounts of data requires considerable time and resources (technical and financial) [23] [24]. Additionally, handling dense hydrogeological data using traditional water quality evaluation methods can lead to information losses or model inaccuracies [25]. Consequently, scholars considered machine learning (ML) a more convenient approach due to its quick, cost-effective, and accurate forecasting capabilities [23] [24] [26] [27]. Machine learning is a multifaceted method that enables insights and interpretation of system behaviors from input data, enhancing holistic water resource management and strategic planning [24] [26] [27]. Moreover, ML can be a relevant alternative in situations lacking exhaustive hydrogeological data for detailed modeling with physics-based models [28].
For two decades, Scholars have significantly employed ML prediction models for their studies in the water management system, including regression techniques such as decision tree regression (DT), boosting ensembles, ridge regression (RR), lasso regression (LR), and the artificial neural network (ANN). The DT regression model has been applied in several studies, such as river water quality prediction [29] or applied in combination with the support vector regression (SVR) for wastewater quality indicator prediction [30]. The boosting ensembles have been used for discharge coefficient estimation [31], arsenic adsorption in water treatment [32], among others. Ridge regression was also used for medium and long-term runoff forecasting [33], groundwater quality forecasting with other models, such as lasso [29], and other techniques. Artificial neural network prediction has been extensively utilized in various studies, including flood susceptibility [34], nitrate or fluoride contamination [35] [36], etc.
The integration of ML in water quality assessment using the WQI method has also gained traction recently [37]. For example, the prediction of some river’s quality index in India was optimized through eight individual machine-learning regression methods, which include DT, Ridge, Lasso, and ANN [29]. The water quality rating scale and water quality weight score were derived as feature sets. The results showed that linear regression (LR) and Ridge trained using the scale accurately predicted WQI, with 𝑀𝑆𝐸 = 0 and 𝑟 = 1, outperforming the existing models. Ahmed et al. [38] applied eight algorithms, such as gradient boosting and polynomial regression, to predict WQI. The Gradient boosting algorithm performs better with MAE = 1.9642, while the polynomial regression has MAE = 2.7273. Yilma et al. [39] forecasted the WQI of the Akaki River using the artificial neural network. The model involved eight hidden layers and 15 hidden neurons predicting WQI with more than 90% accuracy. Gupta et al. [40] proposed an ANN model for predicting WQI using a cascade forward network with the best predictability. Leong et al. [41] developed two models for WQI forecasting: the support vector machine (SVM) with three kernel functions (linear, polynomial, and Radial Basis Function) and the least squares support vector machine (LS-SVM). The polynomial kernel demonstrates the best performance for the SVM, with an R2 of 0.8796. Moreover, the LS-SVM that used pertinent predictors for training had higher accuracy, with an R2 of 0.9227, while the SVM that used all the predictors yielded an R2 of 0.9184.
Past literature reveals that different ML models perform optimally under diverse hydrogeological conditions. Nonetheless, most studies on WQI prediction have employed conventional weight assignment methods. To the best of our knowledge, no research has evaluated Abidjan CT groundwater quality using a WQI based on AHP MCDM. In addition, no investigation into the performance of ML models for groundwater quality prediction in Abidjan has been recorded. To address this gap, this exploratory study aims to predict an AHP-based WQI for Abidjan CT groundwater through three regression algorithms (Ridge, Lasso, and Gradient Boosting). The Continental Terminal groundwater is a vital source for the Abidjan population, and if its quality can be forecasted, this can control and mitigate significant risks. Hence, this research provides novel perspectives on managing Abidjan groundwater through machine learning prediction. Integrating AHP in the WQI method also simplifies and improves the determination of the relative importance of groundwater quality indicators. Lastly, this study allows a regular evaluation framework without the necessity of extensive sampling, laboratory analysis time, and expenses.
2. Study Area
The Continental terminal aquifer considered in this study is predominantly found in the district of Abidjan, the southeastern part of Côte d’Ivoire (Figure 1). The district covers the area between latitude 5˚20'10”N and longitude 4˚01'39”W, with an elevation ranging from 0 to 200m [42]. This region is characterized by an equatorial transitional climate known as the Attieen climate, with two wet seasons (April to July and October to November) and two dry seasons (August to September and December to March) [43]. The geology of Abidjan corresponds to the coastal sedimentary basin, representing 2.5% of Côte d’Ivoire’s surface area and measuring 350 to 400 km long and 40 to 50 km wide [43]. The sedimentary basin in Abidjan is composed of three aquifers: the Quaternary, the Continental Terminal, and the Maastrichtian. The CT aquifer, further north in the basin, covers its entire surface aside from the Quaternary coastal area [44]. The CT aquifer is unconfined from the Mio-Pliocene age formations in the form of high plateaus [42]. These formations are characterized by a lenticular stratification of coarse sands, varicolored clays, ferruginous sandstones, and iron ores [45]. Known as the Abidjan aquifer, CT exploitation accounts for more than 50% of the national drinking water production. The CT groundwater is mainly recharged by two processes: the direct infiltration through the Quaternary formation (upper layer) and the long rainy season, which recharges the groundwater in approximately
Figure 1. CT groundwater sampling location in Abidjan, Côte d’Ivoire: Anonkoua Kouté (AK), Niangon Nord (NN), Djibi (DJI), Nord Riviera (NR), Riviera Centre (RC), Zone Ouest (ZO), Zone Est (ZE), Zone Nord (ZN), Adjamé Nord (AN).
two months and lasts 2 to 4 months [43] [45].
3. Methodology
3.1. Data Collection
In this study, nine sampling sites in the CT groundwater of Abidjan were studied. Given the impact of the rainy season on CT groundwater recharge and imploring the representative sampling method, the National Public Hygiene Laboratory in Abidjan provided data (98 samples/site) from their sampling campaigns from May 2nd to September 1st, 2022. These samples were considered sufficiently representative to approximate the characteristics of the broader population from which they were extracted [46]. A total of twelve indicators have been assessed in compliance with World Health Organization (WHO) specifications, notably pH, electric conductivity (EC), total dissolved solids (TDS), chloride (Cl−), sulfate (
), bicarbonate (
), sodium (Na+), potassium (K+), magnesium (Mg2+), calcium (Ca2+), nitrate (
), and aluminum (Al3+). The methodology comprises two key phases designed to achieve the research objectives. Initially, the computation of the WQI was conducted using the Analytic Hierarchy Process (AHP) to determine the relative weight of parameters. Subsequently, the prediction of the AHP-based WQI was executed, applying the twelve physicochemical parameters as features and the WQI as label.
3.2. Water Quality Index Calculation
The Water Quality Index is a popular method with straightforward mathematical features and a user-friendly interface. This approach uses data or indicators from a water body to determine a unique number. The obtained number is then classified into a category that reflects the water quality status [19]. The analytical hierarchy process (AHP) is a multi-criteria decision analysis method (MCDM) developed by Saaty [47]. In recent years, numerous researchers have used AHP to calculate the relative weight of parameters for different groundwater studies [48]-[50]. This method has the advantage of limiting the possibility of errors and incorrect distribution of weight to a specific parameter [50] [51]. Additionally, the consistency of the approach can be verified after computation, and the pair-wise comparison matrix generated in the calculation is a promising approach for providing relative weights [20].
3.2.1. Parameters Relative Weights Calculation
The AHP-weighting was implemented through a four-step process.
Step 1: The parameters are hierarchically organized considering their nature or function.
Step 2: Scales of 1 to 9 (Table 1) are attributed to the parameters based on their significance in the overall water quality.
Table 1. Saaty’s lineal scale of preferences in the pair-wise comparison process.
Numerical rating |
Judgments of preferences between factor i and j |
1 |
factor i is equally important to factor j |
3 |
factor i is slightly more important than factor j |
5 |
factor i is clearly more important than j |
7 |
factor i is strongly more important than factor j |
9 |
factor i is extremely more important than factor j |
2, 4, 6, 8 |
Intermediate values |
Step 3: The pair-wise comparison matrix is constructed. Considering n evaluation factors and the importance intensity of factor i over j. The pair-wise comparison matrix A gives:
(1)
aij = Wi/Wj ; where Wi and Wj represent the assigned scores to factors i and j, respectively. This value is supposed to approximate the relative importance of i to j.
The factors eigenvectors are then calculated using the average of the normalized column, presented as
; (
)(2)
Step 4: The consistency index (CI) and the consistency ratio (CR) are calculated to validate the judgment of the different values assigned to parameters.
(3)
where
(4)
With n, the pair-wise comparison matrix size, and
, the principal eigenvalue of the matrix A. The consistency is observed only when matrix A is a positive reciprocal one and
is closer to n.
(5)
where
is the product of the geometrical mean of the pair-wise comparison matrix rows and the normalized weight;
is the normalized weight of each variable
.
RCI is the average random consistency index, computed and tabulated as shown in the following Table 2. If CR < 0.1, the numerical judgments will be considered acceptable.
Table 2. Average random consistency index values according to matrix size.
n |
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
RCI |
0.00 |
0.00 |
0.58 |
0.90 |
1.12 |
1.24 |
1.32 |
1.41 |
1.45 |
1.49 |
1.52 |
1.48 |
1.56 |
1.57 |
1.59 |
3.2.2. Calculation of Quality Rating
The calculation is performed using the normalized rating scale (qi), which is obtained by subtracting the measured value of a parameter from the acceptable level and then dividing it all by the permissible level. The equation is formulated as follows:
(6)
where
is the acceptable level set by the WHO [52] for each parameter in drinking water and
is the measured value of this parameter.
3.2.3. Determination of the Index
For computing WQI, the sub-index SI for each parameter gives:
(7)
where
is the normalized weight of the ith parameter.
Then,
(8)
The computed WQI values are finally classified into five categories (Table 3): excellent, good, poor, very poor, and unfit water for drinking purposes [53].
Table 3. Water quality classification ranges.
Range |
Water quality |
<50 |
Excellent water |
50 - 100.1 |
Good water |
100 - 200.1 |
Poor water |
200 - 300.1 |
Very Poor water |
>300 |
Unfit for drinking |
3.3. Machine Learning Prediction
3.3.1. Data Pre-Processing
Our study experiment was conducted in the Windows 11 system, using Python (version 3.11.0) as the programming language for code programming. The data reading and preprocessing via Pandas (version 2.1.4). Machine learning models were built through scikit-learn (version 1.2.2), and matplotlib (version 3.8.0) was used to draw graphics. First, the data preprocessing consisted of filling the missing values with 0 using the Pandas tool. The second step focused on feature scaling, with the min-max normalization technique commonly applied for standardization tasks [54]. These features range between 0 and 1, helping to improve the convergence speed and performance of specific machine-learning algorithms.
(9)
Here,
is the original data,
represents the normalized data,
represents the maximum value of the original data while
represents the minimum value of the original data.
The third step encompasses data splitting into training and test sets. The training set allows ML algorithm data to learn how to generate predictions and uncover insights within the dataset, while the test set is used to execute the model. The current experiment implies time series data, where data before August 1, 2022, were used as the training set and those after August 1, 2022, as the test set. Based on the slide window projection, data features for seven consecutive days have been input in each model’s windows (window size = 10) to enable water quality predictions after seven days.
3.3.2. Learning Algorithms
The basic principle of ridge regression analysis introduced by Hoerl and Kennard [55], established research to estimate biases with a smaller Mean squared error (MSE). By adding a small constant ‘k’ to the diagonal of the correlation matrix of independent variables, the error variance can be considerably reduced to manage the overall instability of ordinary least square (OLS) estimates. The calculation formula gives:
(10)
With
as the ridge estimator, N samples, the constant ‘k,’ the p covariates, and
the covariate vector, as well as
which refers to the shrinkage parameter indicating the larger the value of
, the regression coefficients decline further as they approach zero. Before implementing Ridge regression, the inputs need to be standardized because the obtained solutions are not homogeneous when the input variables are scaled. Also, the intercept
has not been penalized in the Ridge regression.
Lasso is a linear model with regularization, initially introduced in the context of least squares. Tibshirani [56], presented the model as an innovative variable selection mechanism for regression, optimizing the residual sum of squares while constraining the total absolute coefficient magnitudes. Lasso is a well-known regression method that regularizes the parameter β under the sparse assumption [57]. Like ridge regression, the model considers N sample, p covariates, and a single outcome. Supposing
is the response variable, and
is the covariate vector for the ith case
, the following relation gives the mathematical expression:
(11)
In Lasso regression, λ subject is computed to minimize the residual sum of the square:
(12)
The Gradient Boosting (GB) approach is an ensemble learning technique [27] that integrates multiple weak models to enhance overall performance. The GB algorithm consists of three key elements: the loss function, the weak learner, and the additive model. The loss function component must constantly be optimized to reduce the prediction error. Gradient Boosting is based on sequential learning using weak learners like the decision trees model to mitigate the losses without altering the existing tree. Instances mistakenly identified in one phase are assigned additional weight in the subsequent step. This way, each subsequent weak learner is designed to address and rectify the errors made by the previous models [58] [59]. Friedman provided the entire calculation process [60], explained as follows:
Considering the predictors x, the targe y, and the number of observations
.
(13)
where
is the initial constant value prediction and L, the loss function.
Residuals computation:
(14)
for
and
, previous prediction.
for
; with the features x against
, the terminal or leave node and J, the total number of leaves.
Computation of
(15)
for
Model update:
(16)
3.4. Prediction Performance Assessment
Verifying the accuracy of the constructed models is an essential phase in predictions; otherwise, the predictive model would lack scientific significance [61]. The performance assessment indicators for our study’s prediction include the mean square error (MSE), the root mean square error (RMSE), the Pearson, the Spearman, and the Kendall correlations. The Pearson, Spearman, and Kendall correlation coefficients represent the consistency evaluation metrics. These indicators are calculated as follows:
(17)
(18)
where,
is the ith observed value,
is the corresponding predicted value, and n the number of observations.
MSE and RMSE values approaching 0 imply higher prediction accuracy, whereas values approaching 1 reflect lower prediction performance [62].
The correlation coefficients indicate the degree of linear association between two variables, with 1 indicating a positive relationship, -1 indicating a negative relationship, and 0 indicating no linear association [63] [64]. For variables a and b with n data sets (each data set can be labeled ai and bi, where
), the coefficient is used to estimate the correlation r between a and b.
Pearson:
(19)
Spearman:
(20)
Kendall:
(21)
where
and
are the means of a and b, respectively,
is the difference between the two ranks of each variable and
is the number of concordance and
the number of discordances.
4. Results and Discussion
4.1. Physico-Chemical Parameters Evolution
Table 4 presents the descriptive statistics of all the analytical data of the groundwater samples collected from the study area, majorly during the long rainy season. Most parameters were found within permissible limits of the WHO [52], except for K+ and Al3+, which exceeded the permissible thresholds in 4.76% and 3.4% of samples, respectively. In the CT aquifer, water is particularly acidic, with pH values between 4 and 5.9. The primary factor predicting this pH is the acidity of the leached ferrallitic soil of the southern coastal plateau landscapes, which is 3.9 according to the soil record of the Côte d’Ivoire sedimentary basin [65]. Acidic rainwater recharge also influences the pH of the resource [66]. The observed EC varies from 4.1 to 469.0 µS/cm, indicating a low conductivity due to groundwater mixing, as the CT is an unconfined aquifer. After surface recharge enters the aquifer, a significant dilution occurs due to less mineralization and more acidic water [43]. The relatively high values correspond to areas that lack a functional sanitation infrastructure [67]. The observed TDS varies from 0.0629 mg/L to 214.315 mg/L, which ascertains the low salinity of the resource and the groundwater mixture.
The anions order in the overall samples is
> Cl− >
>
. The recorded
level varies between 0 and 240.5 mg/L. In some samples, higher concentrations of HCO3 can be justified by the weathering of silicates [68], occurring when they react with CO2 gas from root respiration and aqueous CO2 from the water, leading to a potential release of Ca, Mg, and HCO3 into the groundwater [69]. The measured concentration of Cl− varies from 1.68 mg/L to 16.908 mg/L, while the nitrate ranges from 0 to 48.73 mg/L. The values of
close to permissible limits are symptomatic of sewage effluent drainage and decomposition of organic material with precipitation in the unconfined CT groundwater. The sulfate content ranges from 0 to 18.4 mg/L as the origins of
in groundwater are mainly from the dissolution or oxidation of sulfate minerals and acidic rainwater recharge [70].
The cationic order in the CT groundwater samples is Ca2+ > Na+ > Mg2+ > K+ >
Table 4. Statistics of groundwater physicochemical parameters for each site.
|
|
EC |
pH |
Cl− |
|
|
|
Na+ |
K+ |
Mg2+ |
Ca2+ |
Al3+ |
TDS |
AK |
Min |
19.56 |
4.5 |
1.82 |
2.02 |
0.025 |
0.01 |
1.066 |
0.01 |
0.002 |
0.5 |
0.013 |
7.773 |
Max |
46.54 |
4.96 |
3.83 |
5.72 |
2.86 |
2.46 |
2.173 |
0.99 |
1.42 |
0.993 |
4.209 |
15.186 |
Mean |
32.297 |
4.651 |
2.629 |
3.934 |
1.291 |
1.070 |
1.854 |
0.272 |
0.588 |
0.713 |
0.164 |
10.911 |
SD |
7.913 |
0.112 |
0.532 |
0.978 |
0.766 |
0.664 |
0.168 |
0.188 |
0.376 |
0.145 |
0.482 |
1.539 |
NN |
Min |
4.1 |
4.3 |
3.61 |
4.5 |
1 |
0.1 |
1.6 |
0 |
0 |
0 |
0.003 |
13.988 |
Max |
51.55 |
5.19 |
4.89 |
7.3 |
2.7 |
0.402 |
2.73 |
2.12 |
1.999 |
0.99 |
0.086 |
20.534 |
Mean |
20.904 |
4.841 |
4.260 |
5.985 |
1.827 |
0.249 |
2.167 |
0.864 |
0.918 |
0.776 |
0.041 |
16.748 |
SD |
15.132 |
0.175 |
0.357 |
0.795 |
0.498 |
0.092 |
0.301 |
0.613 |
0.589 |
0.215 |
0.028 |
1.313 |
DJI |
Min |
5.77 |
4.3 |
2.8 |
4.8 |
0.7 |
0 |
2.5 |
0.2 |
0.4 |
0.4 |
0.001 |
11.353 |
Max |
55 |
5.5 |
5.001 |
13.2 |
2.401 |
9.4 |
4.9 |
1.8 |
1.9 |
1.2 |
0.13 |
25.615 |
Mean |
20.722 |
4.901 |
3.858 |
7.807 |
1.556 |
3.574 |
3.620 |
0.720 |
0.944 |
0.779 |
0.060 |
17.557 |
SD |
12.918 |
0.373 |
0.647 |
2.432 |
0.463 |
2.679 |
0.726 |
0.319 |
0.338 |
0.229 |
0.039 |
3.225 |
NR |
Min |
21.07 |
4 |
3.7 |
4.9 |
0.071 |
0 |
1.056 |
0.1 |
0.5 |
0.33 |
0.001 |
9.069 |
Max |
109.7 |
4.99 |
8.6 |
27.4 |
4.9 |
11.7 |
9.9 |
3.8 |
1.602 |
4.2 |
3.088 |
25.2 |
Mean |
74.483 |
4.456 |
6.059 |
12.109 |
2.223 |
4.257 |
5.100 |
2.102 |
0.935 |
2.303 |
0.153 |
16.593 |
SD |
18.437 |
0.283 |
1.287 |
5.430 |
1.256 |
3.373 |
2.297 |
0.974 |
0.301 |
1.120 |
0.362 |
3.517 |
RC |
Min |
83.6 |
4.07 |
2.5 |
0 |
0.4 |
29.3 |
5.13 |
0.32 |
1.011 |
2.401 |
0.001 |
0.063 |
Max |
151.8 |
5.73 |
6.97 |
8.2 |
1.9 |
67.32 |
11.76 |
3.99 |
3.593 |
11.7 |
0.017 |
71.227 |
Mean |
107.99 |
5.022 |
4.608 |
3.464 |
1.216 |
50.792 |
8.343 |
2.185 |
2.328 |
7.252 |
0.009 |
33.223 |
SD |
22.289 |
0.349 |
1.109 |
2.610 |
0.456 |
11.239 |
1.954 |
1.070 |
0.597 |
2.653 |
0.005 |
25.117 |
ZO |
Min |
41.7 |
4.3 |
4.44 |
0 |
0 |
0 |
3.11 |
0.506 |
0.12 |
0.4 |
0.001 |
4.115 |
Max |
159.4 |
5 |
16.908 |
48.73 |
14.57 |
78.1 |
12.55 |
33.61 |
4.9 |
19.3 |
0.48 |
103.70 |
Mean |
83.2 |
4.623 |
10.066 |
10.331 |
5.362 |
18.139 |
8.254 |
11.013 |
3.045 |
9.515 |
0.048 |
48.564 |
SD |
30.215 |
0.197 |
3.643 |
13.752 |
4.324 |
21.621 |
2.770 |
11.008 |
1.207 |
5.534 |
0.109 |
25.261 |
ZE |
Min |
174.96 |
4.17 |
2.21 |
0 |
0.053 |
56.92 |
9.2 |
0.1 |
2.3 |
5.5 |
0.002 |
0.420 |
Max |
236.3 |
5.84 |
15.3 |
27.3 |
4.55 |
135.2 |
18.7 |
1.29 |
5.81 |
39.9 |
0.103 |
129.91 |
Mean |
201.30 |
4.846 |
7.413 |
9.069 |
2.028 |
96.021 |
13.943 |
0.605 |
4.085 |
14.565 |
0.012 |
62.489 |
SD |
18.107 |
0.349 |
3.274 |
9.336 |
1.236 |
25.202 |
2.846 |
0.344 |
0.942 |
8.826 |
0.022 |
43.873 |
ZN |
Min |
57.2 |
4.8 |
1.9 |
0 |
0.6 |
122.54 |
12 |
0.4 |
5.2 |
18.1 |
0.001 |
118.63 |
Max |
289.33 |
5.5 |
4.93 |
20.48 |
8.8 |
175.6 |
21.48 |
9.81 |
17.07 |
35.06 |
0.052 |
182.68 |
Mean |
205.28 |
5.191 |
3.603 |
4.432 |
3.576 |
148.131 |
17.105 |
4.946 |
9.112 |
26.271 |
0.014 |
143.12 |
SD |
82.370 |
0.211 |
0.775 |
6.963 |
2.804 |
16.114 |
2.416 |
2.824 |
2.923 |
4.756 |
0.015 |
13.119 |
AN |
Min |
298 |
4.5 |
1.68 |
0 |
0 |
169.98 |
6.8 |
0.2 |
10.4 |
38.1 |
0.001 |
154.89 |
Max |
469 |
5.9 |
7.32 |
2.2 |
18.4 |
240.5 |
22.41 |
4.3 |
15.4 |
51.3 |
0.008 |
214.32 |
Mean |
385.89 |
5.161 |
4.220 |
0.893 |
4.981 |
205.446 |
15.646 |
2.252 |
12.88 |
44.071 |
0.004 |
187.67 |
SD |
52.575 |
0.256 |
1.604 |
0.618 |
5.970 |
18.453 |
4.002 |
1.240 |
1.587 |
3.975 |
0.002 |
12.603 |
Al3+. The Ca2+ value indicates variations from 0 to 51.3 mg/L. The primary factors influencing the presence of Ca2+ in groundwater are the calcium-rich silicate weathering and the process of ion exchange [71]. The Na+ concentration fluctuates between 1.056 mg/L and 22.4 mg/L, while the Mg2+ fluctuates between 0 and 17.07 mg/L. The recorded K+ varies between 0 and 33.61 mg/L. High levels of K+ observed in a few samples are due to alteration products such as kaolin in clay formations [72], of the aquifer. For the Al3+ content, the measured concentration ranges between 0.001 mg/L and 4.209 mg/L and the highest Al3+ values potentially come from the geological formation of the CT aquifer [73].
4.2. Water Quality Index
Applying the AHP methodology, the structure was organized into three hierarchies given major ions percentage in samples (Figure 2): (1) physical parameters such as pH, EC, and TDS, (2) chemical parameters like Cl−,
,
, Na+, K+, Mg2+, and Ca2+, and (3) health-threatening chemical parameters such as
and Al3+. Scores of 5 and 9 were respectively given to the first and third structures. The physical variables are undoubtedly essential; however, the health-threatening parameters are paramount in groundwater. Additionally, structure (2) was divided into two subgroups, (a) and (b), with respective rates of 6 and 4 based on anions and cations orders in the samples. The consistency ratio calculation gives CR = 0.024 < 0.1 (Table 5), validating the generated pair-wise matrix. This result of CR enables the application of normalized weights as relative weights for WQI determination.
Figure 2. Hierarchical structure of the selected parameters.
Table 5. Physico-chemical parameters pair-wise comparison matrix.
The obtained index values fluctuate on average between 83.40 and 90.79, with a standard deviation between 0.867 and 14.639 (Table 6). The classification of these indices based on the categories for human consumption indicates good groundwater quality for most samples, corresponding to 98.98%. Moreover, 0.68% of the samples are under the excellent water quality category (<50), while 0.34% of the samples are under the poor water quality category (100 - 200.1) (Table 7). Considering that Al3+ and K+ exceed the permissible thresholds for 4.76% and 3.4% of the samples, respectively. The WQI results and the CT groundwater quality are deemed protected with a minor degree of threat or impairment. The resource conditions represent areas with suitable groundwater for various uses. The Abidjan quaternary groundwater quality assessment presented similar results supporting our study’s outcome [74]. The GWQI also shows that the resource is generally suitable for drinking purposes. In dry season, 70.49% of the samples fall into the category of excellent water quality, 16.39% fall into good water quality class. 55.73% of the samples are classified as excellent in rainy seasons, while 31.13% are good. Since the Quaternary layer is located above the CT layer, the modified classification of some samples can be attributed to the effects of precipitation on the chemical process of water, as observed in CT groundwater.
Table 6. Statistics of the computed WQI for each site.
|
AK |
NN |
DJI |
NR |
RC |
ZO |
ZE |
ZN |
AN |
min |
14.430 |
87.248 |
83.404 |
3.781 |
88.359 |
58.864 |
79.705 |
76.128 |
82.218 |
max |
172.587 |
93.536 |
93.856 |
103.707 |
93.553 |
91.957 |
92.007 |
88.668 |
85.905 |
mean |
89.123 |
90.649 |
89.123 |
83.606 |
90.788 |
84.991 |
87.935 |
84.062 |
83.821 |
SD |
14.639 |
1.852 |
2.621 |
13.341 |
1.049 |
7.754 |
2.832 |
2.481 |
0.867 |
Table 7. CT groundwater quality evaluation summary.
Model |
Total
monitoring sites |
Water quality status |
AHP
weight-based WQI |
9 |
Excellent 0.68% of samples |
Good 98.98% of samples |
Poor 0.34% of samples |
Very poor 0% of sample |
Unfit 0% of sample |
4.3. Prediction Results and Performances
This section provides the outcomes of real-time prediction of CT groundwater quality using Ridge, Lasso, and GB regression models. The twelve physicochemical parameters (pH, EC, TDS, Cl−,
,
, Na+, K+, Mg2+, Ca2+,
and Al3+) represent the features, and the AHP-based WQI are the label. The limited data enables a prediction of resource quality seven days ahead. However, all the models were successfully executed. The algorithm accuracy indicators present performances varying from one model to another. For the interpretation, we only considered the testing set.
4.3.1. Ridge Regression
The real and predicted WQI plots (Figure 3) indicate that the predicted values oscillate within a similar range to the measured values for locations AK, RC, ZO, ZE, and AN. Conversely, the differences between the actual and predicted values are apparent in the remaining sites. In contrast to previous observations, the performance metrics delineated in Table 8 indicate that at these sites (AK, RC, ZO, ZE, and AN), the model has a suboptimal performance (MSE and RMSE close to 1), while the other sites yield good performance (MSE and RMSE close to 0). Additionally, the correlation metrics imply a lack of consistency in the model’s execution across most monitored sites with r, rs, and τ < 0.5.
Figure 3. Actual vs predicted WQI plots for Ridge model at each site (a) Site 1 AK, (b) Site 2 NN, and (c) Site 3 DJI, (d) Site 4 NR, (e) Site 5 RC, (f) Site 6 ZO, (g) Site 7 ZE, (h) Site 8 ZN, (i) Site 9 AN.
Table 8. Groundwater quality prediction performance indicators for Ridge regression for each site.
Sites |
MSE |
RMSE |
Pearson r |
Kendall rs |
Spearman τ |
AK |
0.704 |
0.839 |
0.538 |
0.314 |
0.406 |
NN |
0.192 |
0.438 |
0.703 |
0.193 |
0.298 |
DJI |
0.255 |
0.505 |
0.546 |
0.116 |
0.093 |
NR |
0.303 |
0.551 |
0.420 |
0.010 |
0.012 |
RC |
1.792 |
1.339 |
0.426 |
0.363 |
0.332 |
ZO |
1.001 |
1.000 |
0.457 |
0.159 |
0.234 |
ZE |
1.318 |
1.148 |
0.456 |
0.152 |
0.093 |
ZN |
0.160 |
0.401 |
0.264 |
0.166 |
0.298 |
AN |
2.659 |
1.631 |
0.340 |
0.606 |
0.783 |
mean |
0.924 |
0.834 |
0.427 |
0.204 |
0.252 |
std |
0.774 |
0.418 |
0.136 |
0.167 |
0.216 |
4.3.2. Lasso Regression
The obtained plots (Figure 4) suggested that the predicted WQI values vary within the same range as the measured values for locations AK, NN, NR, RC, ZO,
Figure 4. Actual vs predicted WQI plots for Lasso model at each site (a) Site 1 AK, (b) Site 2 NN, and (c) Site 3 DJI, (d) Site 4 NR, (e) Site 5 RC, (f) Site 6 ZO, (g) Site 7 ZE, (h) Site 8 ZN, (i) Site 9 AN.
and ZN. Meanwhile other sites, DJI, ZE, and ZE, discrepancies are identified between the actual and predicted values at the same time. However, the performance metrics outlined in Table 9 indicate that the model has low performance (MSE and RMSE close to 1) at these sites, while the remaining sites showcase good performance (MSE and RMSE close to 0). Moreover, the indicators exhibit inconsistent model execution for most monitored sites like Ridge regression, with r, rs, and τ close to 0.
Table 9. Groundwater quality prediction performance indicators for Lasso regression for each site.
Sites |
MSE |
RMSE |
Pearson r |
Kendall rs |
Spearman τ |
AK |
7.954 |
2.820 |
0.357 |
0.190 |
0.161 |
NN |
1.032 |
1.016 |
0.629 |
0.109 |
0.107 |
DJI |
0.217 |
0.466 |
0.004 |
0.001 |
0.002 |
NR |
141.417 |
11.892 |
0.630 |
0.002 |
0.002 |
RC |
763.142 |
27.625 |
0.419 |
0.030 |
0.058 |
ZO |
1.377 |
1.173 |
0.513 |
0.094 |
0.093 |
ZE |
0.245 |
0.495 |
0.359 |
0.022 |
0.021 |
ZN |
16.626 |
4.077 |
0.641 |
0.042 |
0.059 |
AN |
0.235 |
0.485 |
0.078 |
0.099 |
0.092 |
mean |
148.921 |
6.828 |
0.397 |
0.079 |
0.082 |
std |
246.561 |
8.653 |
0.213 |
0.063 |
0.059 |
4.3.3. Gradient Boosting Regression
Table 10 presents the results of the gradient-boosting regression performance evaluation for the CT groundwater quality prediction. The computed metrics at each site display satisfactory performance and consistency in the prediction. This is translated by the low error levels (close to 0) and high correlations (close to 1), with values ranging from 0.097 to 0.112 and 0.311 to 0.334 for MSE and RMSE, respectively. Also, r ranges from 0.439 to 0.966, rs from 0.632 to 0.904, and τ from 0.836 to 0.945. The real and predicted WQI plots (Figure 5) variations corroborate
Table 10. Groundwater quality prediction performance indicators for GB regression for each site.
Sites |
MSE |
RMSE |
Pearson r |
Kendall rs |
Spearman τ |
AK |
0.097 |
0.311 |
0.880 |
0.904 |
0.945 |
NN |
0.106 |
0.325 |
0.966 |
0.853 |
0.836 |
DJI |
0.097 |
0.311 |
0.880 |
0.904 |
0.945 |
NR |
0.104 |
0.323 |
0.879 |
0.858 |
0.890 |
RC |
0.112 |
0.334 |
0.439 |
0.632 |
0.836 |
ZO |
0.106 |
0.325 |
0.966 |
0.853 |
0.836 |
ZE |
0.106 |
0.325 |
0.966 |
0.853 |
0.836 |
ZN |
0.112 |
0.334 |
0.439 |
0.632 |
0.836 |
AN |
0.106 |
0.325 |
0.966 |
0.853 |
0.836 |
mean |
0.097 |
0.300 |
0.766 |
0.757 |
0.804 |
std |
0.023 |
0.069 |
0.257 |
0.198 |
0.189 |
Figure 5. Actual vs predicted WQI plots for GB model at each site (a) Site 1 AK, (b) Site 2 NN, and (c) Site 3 DJI, (d) Site 4 NR, (e) Site 5 RC, (f) Site 6 ZO, (g) Site 7 ZE, (h) Site 8 ZN, (i) Site 9 AN.
the performance metrics results, showing fluctuation of predicted values in line with the trend of actual values in all sites. This confirms the accuracy of the Gradient-boosting model.
4.4. Discussion
In the last decade, WQI models have been widely used to assess water quality for various contexts. Nonetheless, a major challenge faced while using WQIs is the uncertainties from incorrect weight assignment in the methodology [20]. Our study agrees that the AHP weight-based WQI model represents the ideal approach, highlighting its advantages over alternative models like weighted arithmetic WQI or entropy weight-based WQI. The AHP model allows for a systematic and structured approach to decision-making, ensuring that the most critical parameters are emphasized in the evaluation process [75]. This model focuses on the uncertainty in the data as well as considers the contextual significance of certain parameters that are better evaluated through expert input [20] [76]. Additionally, the AHP model’s flexibility allows for incorporating local knowledge and specific health impacts associated with groundwater quality parameters, making it more suitable for targeted assessments in diverse environments [77].
Regarding the prediction phase, the three regression models (Ridge, Lasso, and Gradient Boosting) were executed. Choosing these models over others like random forest, artificial neural network, or deep learning can be attributed to different factors. First, the interpretability of ridge and lasso regression is significantly higher. For instance, Deep learning might give accurate predictions, however, hardly show how predictions are made, leading to its identification as “black boxes” [78], posing limitations as researchers and stakeholders need to trust or understand the results. The ability to interpret prediction outcomes is essential for effective management and policymaking [29]. Next, these complex models typically require large datasets to train accurately and avoid overfitting. In the current framework, the available datasets do not effectively support such models. In contrast, traditional regression models can perform well even with smaller datasets, making them more practical for our scenario. Then, simpler models, such as ridge, lasso, and gradient boosting, not only require less computational power, but, they also allow for quicker deployment in real-time monitoring systems [38].
Table 11. Average values of the model performance metrics.
Models |
MSE |
RMSE |
Pearson r |
Kendall rs |
Spearman τ |
Ridge |
0.924 |
0.834 |
0.427 |
0.204 |
0.252 |
Lasso |
148.921 |
6.828 |
0.397 |
0.079 |
0.082 |
GB |
0.097 |
0.300 |
0.766 |
0.757 |
0.804 |
To interpret the forecast results, the mean values of the performance metrics for each model were calculated (Table 11). This enabled their comparison and the identification of the best model. The performance metrics lie in their ability to quantitatively assess prediction model accuracy and inform stakeholders about prediction reliability. In groundwater quality scenarios, a model with low error rates (MSE) and high correlations is reliable, providing a clear view of resource quality variation over time [79]. This is essential for understanding the strengths and limitations of different models, allowing their recalibration, the integration of multiple approaches, or additional monitoring to improve overall prediction robustness. These error metrics extend beyond academic interest as RMSE values can be used to establish confidence intervals around predictions [80], while correlation coefficients serve as the measure of the strength and direction of the model. The correlations also capture real-world relationships in the groundwater quality parameters [79]. In practical decision-making, performance metrics are crucial indicators for resource allocation, pollution prevention, and the establishment of informed remediation strategies to inform plans for future water demands [81]. Ultimately, they develop evidence-based policies to justify investments and create sustainable decision-support systems.
Our findings indicate that the GB regression has the lowest values for MSE and RMSE (MSE = 0.097; RMSE = 0.300). Conversely, both Lasso and Ridge regression display significant errors, with Lasso regression recording the highest MSE and RMSE figures (148.921; 6.828). These metric outcomes suggest that GB potentially outperforms Lasso and Ridge regarding predictive accuracy. Nonetheless, obtaining smaller RMSE and MSE does not necessarily indicate excellent models due to their exclusive representation of the mean of squared variances between the forecast and observation failing to reveal the inherent logical bias [28]. The computation of Pearson, Spearman, and Kendall correlation coefficients was performed to identify the variance in model performance and ascertain their consistency [64]. In agreement with the performance metrics, the correlation coefficients reveal that GB demonstrates the most significant level of uniformity while Lasso indicates the lowest, highlighting the differences in predicted and actual WQI values between Lasso and Ridge compared to GB. This outcome was supported by Chen and Guestrin [82], who stated that GB encapsulates complex patterns in a way that other models are unable to. Discrepancies between the performance rates and the calculated correlations were also observed. For instance, in Lasso regression prediction, the metrics suggested an excellent performance in the ZE site (MSE = 0.245 and RMSE = 0.485), while the consistency evaluation presented weak consistency for the same site (r = 0.359; rs = 0.022; τ = 0.021). Thus, the Lasso and Ridge prediction potentially involves systematic biases.
Other researchers have argued that components such as model fitting can lead to systematic instability and bias [28]. An effective data-splitting approach should support the models in grasping the statistical patterns of the input and prevent the introduction of excessive bias. Our study divided sample data into training and testing subsets rather than training, testing, and validation subsets due to the limited sample size (4 months) and the significance of avoiding underestimation of the observed groundwater quality. As a result, the conventional training and testing window selection technique was employed for data splitting [83]. Therefore, three-quarters of the sample size was selected as the training set (data before August 1, 2022) and the rest as the testing set (data after August 1, 2022). The test set included daily sampling data for over one month, representing a short period that can hinder the ability of the model to capture the overall dynamic trend. However, identifying changes in groundwater quality over four months of observation under the same seasonal conditions was a complex challenge. Hence, both Lasso and Ridge regression experienced limitations due to the small sample size and the absence of diversity in the data categories, which used solely physicochemical parameters. Furthermore, Lasso and Ridge models exhibit limited capabilities in forecasting nonlinear occurrences compared to GB regression [28]. This outcome implores the hydrogeochemical process, which embodies nonlinear relationships and a diverse array of interactions within the subsurface environment [84] [85]. By iteratively fitting new models to the errors of the previous models, GB can learn complex patterns and interactions between variables [58] [59], implying the model’s suitability for our study.
5. Conclusions
This research was designed to evaluate the quality of the CT groundwater in Abidjan using the water quality index (WQI) based on the analytical hierarchy process (AHP) and multi-criteria decision analysis methodology (MCDM). Additionally, this study aimed to improve its proposed frameworks for continuous resource quality monitoring by applying machine learning predictions. The efficacy of the models was assessed through a comprehensive analysis using a range of statistical approaches comprising of prediction performance metrics (RMSE, MSE) and model consistency (Pearson, Spearman, and Kendall correlation). First, the results of the research reveal that most of the groundwater quality parameters across the sampling sites are within the World Health Organization (WHO) guideline values except for the aluminum (Al3+) and potassium (K+) that exceeded the permissible thresholds of 4.76% and 3.4% of samples, respectively. Next, the AHP-based WQI model classified the CT groundwater quality averagely into “good” category, with 0.68% in “excellent” and 0.34% in “poor” categories. The groundwater quality is deemed protected with a minor degree of threat or impairment with conditions comparable to areas with suitable groundwater for various uses. Then, the performance evaluation indicated that the gradient boosting (GB) regression model optimally predicted the CT groundwater quality. The GB outperformed the other models by providing the highest accuracy with MSE = 0.097 and RMSE = 0.300, in addition to a remarkable consistency with Pearson, Spearman, and Kendall correlations respectively stated as, r = 0.766, rs = 0.757, and τ = 0.804. Conversely, the lowest prediction accuracy was recorded for the Lasso model with an MSE and RMSE of 148.921 and 6.828 respectively, and consistency parameters of r = 0.397, rs = 0.079, and τ = 0.082 respectively. Both Lasso and Ridge regression faced limitations due to the small sample size and the lack of data diversity. Our study considered a single rainy season dataset and major ions, however, multiple-season data and parameters may have provided greater insight into the groundwater quality of this study. Also, these models struggle with forecasting nonlinear events compared to GB regression, considering that the hydrogeochemical process embodies nonlinear relationships and diverse interactions within the subsurface environment. Through weak learners, GB can learn intricate patterns and interactions between variables by iteratively fitting new models to errors of previous models. With continuous data updates and the application of ensemble models like GB, a groundwater quality prediction monitoring system may be established for efficient water resource management in Abidjan.
In summary, this exploratory study not only provided the assessment and prediction of groundwater quality but also provided novel actionable insights for the effective management of water resources. The implications for groundwater management policy in Abidjan and the whole country are as follows; the integration of real-time monitoring systems, enhanced pollution risk assessment frameworks, regulatory frameworks for groundwater protection, data-driven decision-making, investment in infrastructure, long-term planning and sustainability, collaboration across sectors, and continuous improvement.