The prediction of bus arrival time is important for passengers who want to determine their departure time and reduce anxiety at bus stops that lack timetables. The random forests based on the near neighbor (RFNN) method is proposed in this article to predict bus travel time, which has been calibrated and validated with real‐world data. A case study with two bus routes is conducted, and the proposed RFNN is compared with four methods: linear regression (LR), k‐nearest neighbors (KNN), support vector machine (SVM), and classic random forest (RF). The results indicate that the proposed model achieves high accuracy. That is, one bus route has the results of 13.65 mean absolute error (MAE), 6.90% mean absolute percentage error (MAPE), 26.37 root mean squared error (RMSE) and 13.77 (MAE), 7.58% (MAPE), 29.01 (RMSE), respectively. RFNN has a longer computation time of 44,301 seconds for a data set with 14,182 data. The proposed method can be optimized by the technology of parallel computing and can be applied to real‐time prediction.
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.