# Short-Term Travel Demand Prediction of Online Ride-Hailing Based on Multi-Factor GRU Model
## 4 Result Analysis
### The Comparison of Predicted Results  
We next analyze the improved GRU model proposed in this paper and the original GRU model for evaluation indexes. The two models are used to predict the same set of data, and the parameter values of the two models are the same as those in Table 3.  
As shown in Figure 7 below, the black polyline represents the real data of the test set, while the red and blue polylines represent the test data of the improved GRU model and the original GRU model, respectively. The abscissa of the figure is the data number of the test set, which is the number of data in the prediction set sorted by time series, and the ordinate is the number of travel demand. It is clear that the red line fits better than the blue, which indicates that the improved GRU model predicts better results than the original GRU model. \begin{table}
\begin{tabular}{c c} \hline \hline
**Metric** & **Formula** \\ \hline RMSE & \(RMSE=\sqrt{\frac{1}{n}\sum\limits_{i=1}^{n}{(y_{p}-y)^{2}}}\) \\ MAE & \(MAE=\frac{1}{n}\sum\limits_{i=1}^{n}{|y_{p}-y|}\) \\ MAPE & \(MAPE=\frac{100\%}{n}\sum\limits_{i=1}^{n}{\frac{|y-y_{i}|}{|y|}}\) \\ \(R2\) score & \(R^{2}=1-\frac{\sum\
olimits_{i=0}^{n-1}{(y_{p}-y)^{2}}}{\sum\
olimits_{i=0}^{n- 1}{(y-\overline{y})}}\) \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Predictive evaluation index formula. Figure 8 shows the prediction results of the two models on a rainy day. The figure above selects the data of the rainy day on 30 May in the test set, in which the red poly-line is the improved GRU model, the blue polyline is the ordinary GRU model, and the black column is the rainfall in that hour. It can be seen that the prediction result of the improved GRU model is better than that of the ordinary GRU model when the rainfall increases sharply. Figure 8: Comparison of predictions for a rainy day. Figure 7: Comparison line chart of the two models. Figure 9 shows the prediction results of the two models on a rest day. This figure selects the data on Sunday, 28 May. The red polyline is the improved GRU model, and the blue polyline is the ordinary GRU model. It can be seen that the prediction accuracy of the improved GRU model on Sunday is also much higher than that of the ordinary GRU model. The RMSE, MAE, MAPE, and \(R^{2}\) values of each test set were obtained by making five predictions for the two models, respectively, and then these evaluation indexes of the two models were compared. From Table 5, the average value of each evaluation index obtained from the five prediction results was calculated. By comparing the average values of each index of the two models, it can be seen that the improved GRU model proposed in this paper is better than the original GRU model in each evaluation index. Compared with the original GRU model, the RMSE index value of the proposed improved GRU model is reduced by 56.79%, the MAE value is decreased by 49.40%, the MAPE value is decreased by 27.91%, and the \(R^{2}\) value is increased by 25.71%. The same values for training times and the number of neurons and hidden layers were used for each of the above four models, after which the training results of the respective models were contrasted. The improved GRU model in this paper is compared with the original GRU model and two popular LSTM and RNN models under the same set of data.