Creating accurate predictions in the stock market has always been a great challenge in the finance world but is foundational for a good algorithmic trading system. With the rise of machine learning as the next level of development in the forecasting area, this research paper implements and compares four machine learning algorithms and their accuracy in forecasting three well-known stocks traded in the North American stock market in the short term over the period from March 2020 to May 2022. In addition to the time series of historical stock prices, several exogenous financial and economic variables such as stock market indexes, interest rates, and inflation-related variables are included in the modelling process to mimic their anticipated impact on individual stock prices. We deploy, develop, tune, and evaluate several XGBoost, Random Forest, Multi-layer Perceptron, and Support Vector Regression models and report those that produce the highest level of accuracy from our evaluation metrics: Root Mean Square Error, Mean Average Percent Error, and Mean Positive Error. The evaluation also includes an evaluation of the average training time of these algorithms. Using a training data set of 240 trading days, we find that the XGBoost algorithm gives the highest level of accuracy despite taking longer (up to 10 seconds) to run. Results from this study may improve with the further tuning of the individual parameters of the algorithms and the introduction of other exogenous variables such as company demographics or social sentiment on the stock market.
Paper
References (22)
Scroll for more · 10 remaining