## 3 Empirical Analysis
### Forecasting Effect Test for DE-GWO-SVM Model  
The data from 1990 to 2009 are taken as the training set, and the test set is the data from 2010 to 2016. The DE-GWO-SVM model is adopted to predict the power grid investment in China. The algorithm parameters settings are shown in Table 3.  
The prediction result and the residuals are shown in Figure 4.  
According to Figure 4, using the DE-GWO-SVM model to forecast the power grid investment in China can achieve high prediction precision. In order to ensure the reliability of the experimental results of the prediction model, k-fold cross validation is selected to do the cross validation of the same sample. The original data is divided into four groups. One group of data is taken as the test set, and the others are used as the training set. Every group of data will be test and the forecasting effect is evaluated by \(MAPE\) (mean absolute percentage error). The calculation equation of \(MAPE\) is shown as  
\[MAPE=\frac{1}{n}\sum_{i=1}^{n}\left|\frac{\hat{y}_{i}-y_{i}}{y_{i}}\right| \tag{29}\]  
where \(\hat{y}_{i}\) is the predicted value; \(y_{i}\) is the actual value; \(n\) is the sample size. \begin{table}
\begin{tabular}{c c c c c c} \hline \hline \multirow{2}{*}{**Year**} & **Power Grid** & \multirow{2}{*}{**GDP**} & **Total Electricity** & \multirow{2}{*}{**Electticity Sales**} & **Power Transmission** & **Transformer** \\  & **Investment** & & & **Consumption** & **Line Length of** & **Capacity of 220 kV** \\  & & & & & **220 kV and Above** & **and Above** \\ \hline
1990 & 0 & 0 & 0 & 0 & 0 \\
1991 & 0.0022 & 0.0043 & 0.0108 & 0.0164 & 0.0087 & 0.0086 \\
1992 & 0.0058 & 0. Through cross validation, the overall mean absolute percentage error of the sample is 2.29%, which proves the reliability of the model. For testing the validity and superiority of the DE-GWO-SVM model for China's power grid investment forecasting further, three models (GWO-SVM, SVM, and BP) are selected to make a comparison with the DE-GWO-SVM model by the same sample. The fitting degrees between the prediction curves and the actual curve are shown in Figure 5.  
The relative errors of every prediction point by models are shown in Figure 6.  
Figure 4: The prediction and residual figures. (**a**) The prediction figure; (**b**) The residual figure. Figure 5: Forecasting results comparison. For evaluating the prediction effect of each model more objectively, \(MAPE\) (mean absolute percentage error), \(RMSE\) (root mean square error), and \(MAE\) (mean absolute error) are applied to compare the prediction accuracy of different models. The calculation equations of \(RMSE\) and \(MAE\) are shown as  
\[RMSE=\sqrt{\frac{1}{n}\sum\limits_{i=1}^{n}{\left({{{\hat{y}}_{i}}-{{y}_{i}}} \right)^{2}}} \tag{30}\]  
\[MAE=\frac{1}{n}\sum\limits_{i=1}^{n}{\left|{{{\hat{y}}_{i}}-{{y}_{i}}}\right|} \tag{31}\]  
where \({{{\hat{y}}_{i}}}\) is the predicted value; \({{y}_{i}}\) is the actual value; \(n\) is the sample size. The calculation results of \(MAPE\), \(RMSE\), and \(MAE\) for every model are shown below. Figure 5 shows the fitting degree between the power grid investment curve forecasted by different models and the actual curve of power grid investment. Figure 6 shows the relative errors of each model for power grid investment forecasting. It can be seen that DE-GWO-SVM has the best prediction effect. From Table 4, it can be found that \(MAPE\), \(RMSE\), and \(MAE\) of the DE-GWO-SVM model is the smallest in all models, reaching 1.70, 9.36, and 6.31% respectively. Next is the GWO-SVM model, the \(MAPE\), \(RMSE\) and \(MAE\) are 2.54%, 13.22, and 10.58 respectively. The \(MAPE\), \(RMSE\), and \(MAE\) of BP model is the largest, reaching 5.25, 22.63, and 21.01% respectively. Besides, SVM model has a better forecasting effect than BP. In a word, the three indexes for four models are basically the same in the evaluation results. The prediction precision is ranked as follows: DE-GWO-SVM > GWO-SVM > SVM > BP.