## 3 The Proposed Forecast Combination Methodology
**Step 5. ** We found the in-sample forecasting error of each model through some suitable error measures. We used the mean absolute error (MAE) and the mean squared error (MSE). These are widely popular error statistics [68], and their mathematical formulation is presented below in this paper. In the present study, we adopted the MSE and MAE to find the in-sample forecasting errors of the component models. **Step 6. ** Based on the obtained in-sample forecasting errors, we assigned a score to each component model as \(\gamma_{i}=\frac{1}{MSE\ \Upsilon_{\text{vd}},\ \hat{\Upsilon}_{\text{td}}^{i}}\), \(\forall i=1,\ 2,\ \dots,\ n\). The scores are assigned to be inversely proportional to the respective errors so that a model with a comparatively smaller in-sample error receives more score and vice versa. **Step 7. ** We assigned a rank \(r_{i}\in\ 1,\ 2,\ \dots,\ n\) to the \(i^{th}\) model, based on its score, so that \(r_{i}\geq\ r_{j}\), if \(\gamma_{i}\leq\gamma_{j}\), \(\forall i,j=1,\ 2,\ \dots,\ n\). The minimum, i.e., the best rank is equal to 1 and the maximum, i.e., the worst rank is at most equal to \(n\). **Step 8. ** We chose a number \(n_{r}\) so that \(1\leq n_{r}\leq n\) and let \(I=i_{1},\ i_{2},\ \dots,\ i_{n_{r}}\) be the index set of the \(n_{r}\) component models, whose ranks are in the range [1, \(n_{r}\)]. So, we selected a subgroup of \(n_{r}\) smallest ranked component models. **Step 9. ** Finally, we obtained the weighted linear combination of these selected \(n_{r}\) component forecasts, as follows:  
\[\hat{y}_{k}=w_{i_{1}}\hat{y}_{k}^{i_{1}}+w_{i_{2}}\hat{y}_{k}^{i_{2}}+\dots+ \ w_{i_{tr}}\hat{y}_{k}^{i_{w}}=\sum_{i\in I}w_{i}\hat{y}_{k}^{i_{r}},\ \ \forall i=1,\ 2,\ \dots,\ n \tag{19}\]  
Figure 3: The proposed forecasting combination approach using ensemble methods and ensemble forecasters. Here, \(w_{i_{k}}=\frac{\gamma_{i_{k}}}{\sum_{k=1}^{n_{r}}\gamma_{i_{k}}}\) is the normalized weight to the selected component model, so that \(\sum_{k=1}^{n_{r}}w_{i_{k}}=1\). **Step 10. ** The simple average method could be also adopted, as an alternative to Step 6-9, to calculate the forecasted value. The validation set was used during the training process for updating the algorithm weights appropriately and, thus, improving its performance and avoiding overfitting. After training the model, we could run it on the testing data, to verify if it has predicted them correctly and, if it has been so, to keep hidden the validation set. The most popular and widely used performance metrics or evaluation criteria for time series prediction are the following: coefficient of determination (R2), mean square error (MSE), root mean square error (RMSE), mean absolute error (MAE), and mean absolute percentage error (MAPE). The mathematical equations of all these statistical indicators were described in the study [69]. The goodness of fit and the performance of the studied models, when they applied to a natural gas prediction process, were evaluated and compared using two of these five commonly used statistical indicators, namely, the MSE and the MAE [9]. In particular, the performance of the analyzed approaches for natural gas prediction was evaluated based on the following criteria:  
1. Mean squared error: \[\text{MSE}=\frac{1}{T}\sum_{t=1}^{T}(Z(t)-X(t))^{2}\] (20)
2. Mean absolute error: \[\text{MAE}=\frac{1}{T}\sum_{t=1}^{T}\left|Z(t)-X(t)\right|\] (21)  
where \(X(t)\) is the predicted value of the neural gas at the \(t\)th iteration, \(Z(t)\) is the desired value of the neural gas at the \(t\)th iteration, \(t=1\),..., \(N_{ls}\), and \(N_{ls}\) is the number of testing records. The lower values of the MSE and MAE indicate that the model performance is better with respect to the prediction accuracy, and the regression line fits the data well. All the modeling approaches, tests, and evaluations were performed with the use of the ISEMK (intelligent expert system based on cognitive maps) software tool [66], in which all the algorithms based on ANNs, FCMs, and their hybrid combinations were developed.