# Short-Term Wind Speed Prediction Based on Principal Component Analysis and LSTM
## 3 Case Study
### Prediction Result Analysis  
Case I was to demonstrate the effectiveness of the LSTM model optimized by the DE algorithm compared with the BPNN, GPR, RNN, and SVR models. The forecasting indicators obtained from the above models are shown in Table 4, where the best results for each model are in bold. For the LSTM model, the average values of RMSE, MAE, MAPE, and \(R^{2}\) were 0.3327, 0.2598, 0.1004, and 0.9655, respectively. Compared with other models, the LSTM model optimized by DE performed the best in RMSE, MAE, and \(R^{2}\). In order to more intuitively compare the above five models, the forecasting wind speed and \(R^{2}\) for each model are shown in Figure 5. The coefficient of determination of the LSTM model was the largest. So, the fitting effect was the best and the prediction was the most accurate. To summarize, the LSTM model optimized by the DE algorithm provided better performance than the other four traditional models. \begin{table}
\begin{tabular}{c c c c c c} \hline \hline
**Model** & **Statistical Indicators** & **RMSE** & **MAPE** & **MAE** & \(\mathbf{R^{2}}\) \\ \hline \multirow{3}{*}{BPNN} & Min & 0.8038 & 0.2022 & 0.6138 & 0.6967 \\  & Mean & 0.8435 & 0.2109 & 0.6344 & 0.879 \\  & Max & 1.029 & 0.2447 & 0.721 & 0.9518 \\ \hline GPR & / & 0.8034 & 0.2054 & 0.619 & 0.8688 \\ \hline \multirow{3}{*}{LSTM} & Min & 0.3198 & 0.0930 & 0.2386 & 0.9471 \\  & Mean & 0.3327 & 0.1004 & 0.2598 & 0.9655 \\  & Max & 0.3483 & 0.1077 & 0.2753 & 0.9791 \\ \hline \multirow{3}{*}{RNN} & Min & 0.8026 & 0.0507 & 0.6188 & 0.8601 \\  & Mean & 0.8044 & 0.0521 & 0.6193 & 0.8666 \\ \cline{1-1}  & Max & 0.8075 & 0.0533 & 0.6199 & 0.8723 \\ \hline SVR & / & 0.8292 & 0.1864 & 0.6099 & 0.8814 \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Evaluation prediction results in Case I. \begin{table}
\begin{tabular}{c c c c} \hline \hline
**Model** & **Parameters** & **Value** & **Reason** \\ \hline \multirow{3}{*}{LSTM Feature-LSTM Proposed Model} & Learning rate & 0.0047 & Obtained by DE \\  & Hidden unit & 68 & Obtained by DE \\  & Batch size & 29 & Obtained by DE \\  & Epochs of training & 1000 & Converged \\ \hline \multirow{3}{*}{BPNN Feature-BPNN PCA-BPNN} & Hidden unit & 10 & Common value \\  & Epochs of training & 1000 & Converged \\ \hline SVR & Kernel function & Radial Basis Function & A competitive kernel \\  & Feature-SVR & Parameter in Radial & \multirow{2}{*}{1} & \multirow{2}{*}{Common value} \\ PCA-SVR & Basis Function & & & \\ \hline \multirow{3}{*}{GPR Feature-GPR} & Kernel Function & Gaussian Function & A competitive kernel \\  & Parameter in Gaussian & \multirow{2}{*}{2} & \multirow{2}{*}{Common value} \\  & & & & function \\ \cline{1-1}  & & & & function \\ \hline \multirow{3}{*}{RNN Feature-RNN PCA-RNN} & Hidden unit & 10 & Common value \\ \cline{1-1}  & & & & Converged \\ \hline \hline \end{tabular}
\end{table} 
Table 3: Parameter settings. In Case II, we used meteorological characteristics related to wind speed as input of the five forecasting models. Table 5 and Figure 6 show the performance metrics of forecasting results achieved by the above five different models. RMSE, MAPE, and MAE of the Feature-LSTM model were 0.1745, 0.0488, and 0.1212, respectively. \(R^{2}\) of the Feature-LSTM was 0.9749, which was slightly smaller than that of Feature-BPNN. Overall, the comprehensive prediction performance of the Feature-LSTM was the best among all the above models. Compared with Case 1, all four indicators improved significantly. The prediction results based on the PCA and LSTM methods of Case III are shown in Figure 7. The figure shows the true values and the predicted values of the five different models. Table 6 is the evaluation index value of each prediction model. Through comparing PCA-LSTM with the PCA-BPNN, PCA-GPR, PCA-RNN, and PCA-SVR models, it can be clearly observed that combined methods had an apparent influence on forecasting performance.