# Multi-Step Traffic Speed Prediction Based on Ensemble Learning on an Urban Road Network
## 5 Discussion
### Prediction Stability  
Figure 6 shows the boxplots for the one-week prediction error and one will find that, for the northbound prediction, the number of positive errors is larger than the number of negative errors for different prediction steps; that is, most northbound prediction outputs are larger than the observed values, whereas the number of positive errors is roughly equal to the number of negative errors for the southbound traffic. For the same prediction step, the fluctuation of the northbound prediction errors is smaller than southbound. For example, the northbound one-step prediction error range is [-7.57,17.12], while southbound is [-16.06,17.50].  
The cumulative distribution function (CDF) is an integral of the probability density function, which provides a complete description of the probability distribution of a real random variable. The CDFs of five prediction models are plotted in Figure 7, where the x axis is the deviation of prediction error, and the y axis is the cumulative probability. One can found out that the sequence of model prediction performance from good to bad is DDSELM, BAGGING, KNN, CATBOOST, and SVM. The DDSELM also can provide much more stability than others. For northbound prediction, the 83.33% of its one-step-ahead prediction has error less than 10%, 71.42% for two-step-ahead, and 70.83% for three-step-ahead, respectively. Correspondingly, the prediction error of less than 10% accounts for 71.42% for one-step-ahead, 60.11% for two-step-ahead, and 58.76% for three-step-ahead for southbound prediction, respectively.  
Figure 6: Comparison between the real speed and the predicted speed in boxplots: (**a**) one-step-ahead prediction error in northbound; (**b**) two-step-ahead prediction error in northbound; (**c**) three-step-ahead prediction error in northbound; (**d**) one-step-ahead prediction error in southbound; (**e**) two-step-ahead prediction error in southbound; (**f**) three-step-ahead prediction error in southbound.  
The CV is an important indicator to measure the diversity of data. Compared with other prediction models, the CV of DDSELM has the minimum score regardless of prediction step as shown in Figure 8. Compared with other four models, DDSELM has lower CV, reaching 0.09, 0.10, and 0.11 for one-step-ahead, two-step-ahead, and three-step-ahead prediction, respectively, in Figure 8a. In the south direction, the CVs are similar to those of north direction except the south direction has higher CVs because of the lower correlation mentioned in Section 4.  
Figure 8: Performance of five predictive models’ results in CVs: (**a**) CVs of predictive results in northbound; (**b**) CVs of predictive results in southbound  
Figure 7: Cumulative distribution function of five prediction models: (**a**) one-step-ahead prediction CDF in northbound; (**b**) two-step-ahead prediction CDF in northbound; (**c**) three-step-ahead prediction CDF in northbound; (**d**) one-step-ahead prediction error in southbound; (**e**) two-step-ahead prediction CDF in southbound; (**f**) three-step-ahead prediction CDF in southbound.