IDEAS home Printed from https://ideas.repec.org/p/arx/papers/2309.00618.html
   My bibliography  Save this paper

Short-Term Stock Price Forecasting using exogenous variables and Machine Learning Algorithms

Author

Listed:
  • Albert Wong
  • Steven Whang
  • Emilio Sagre
  • Niha Sachin
  • Gustavo Dutra
  • Yew-Wei Lim
  • Gaetan Hains
  • Youry Khmelevsky
  • Frank Zhang

Abstract

Creating accurate predictions in the stock market has always been a significant challenge in finance. With the rise of machine learning as the next level in the forecasting area, this research paper compares four machine learning models and their accuracy in forecasting three well-known stocks traded in the NYSE in the short term from March 2020 to May 2022. We deploy, develop, and tune XGBoost, Random Forest, Multi-layer Perceptron, and Support Vector Regression models. We report the models that produce the highest accuracies from our evaluation metrics: RMSE, MAPE, MTT, and MPE. Using a training data set of 240 trading days, we find that XGBoost gives the highest accuracy despite running longer (up to 10 seconds). Results from this study may improve by further tuning the individual parameters or introducing more exogenous variables.

Suggested Citation

  • Albert Wong & Steven Whang & Emilio Sagre & Niha Sachin & Gustavo Dutra & Yew-Wei Lim & Gaetan Hains & Youry Khmelevsky & Frank Zhang, 2023. "Short-Term Stock Price Forecasting using exogenous variables and Machine Learning Algorithms," Papers 2309.00618, arXiv.org.
  • Handle: RePEc:arx:papers:2309.00618
    as

    Download full text from publisher

    File URL: http://arxiv.org/pdf/2309.00618
    File Function: Latest version
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Apergis, Nicholas & Miller, Stephen M., 2009. "Do structural oil-market shocks affect stock prices?," Energy Economics, Elsevier, vol. 31(4), pages 569-575, July.
    2. Akoum, Ibrahim & Graham, Michael & Kivihaho, Jarno & Nikkinen, Jussi & Omran, Mohammed, 2012. "Co-movement of oil and stock prices in the GCC region: A wavelet analysis," The Quarterly Review of Economics and Finance, Elsevier, vol. 52(4), pages 385-394.
    3. Narayan, Paresh Kumar & Narayan, Seema, 2010. "Modelling the impact of oil prices on Vietnam's stock prices," Applied Energy, Elsevier, vol. 87(1), pages 356-361, January.
    4. Kwan, Simon H., 1996. "Firm-specific information and the correlation between individual stocks and bonds," Journal of Financial Economics, Elsevier, vol. 40(1), pages 63-80, January.
    5. Alireza Namdari & Tariq S. Durrani, 2021. "A Multilayer Feedforward Perceptron Model in Neural Networks for Predicting Stock Market Short-term Trends," SN Operations Research Forum, Springer, vol. 2(3), pages 1-30, September.
    6. Srinivasan P., 2014. "Gold Price, Stock Price and Exchange rate Nexus: The Case of India," Romanian Economic Journal, Department of International Business and Economics from the Academy of Economic Studies Bucharest, vol. 17(52), pages 77-94, June.
    7. Kim, Sangbae & In, Francis, 2007. "On the relationship between changes in stock prices and bond yields in the G7 countries: Wavelet analysis," Journal of International Financial Markets, Institutions and Money, Elsevier, vol. 17(2), pages 167-179, April.
    8. Engsted, Tom & Tanggaard, Carsten, 2001. "The Danish stock and bond markets: comovement, return predictability and variance decomposition," Journal of Empirical Finance, Elsevier, vol. 8(3), pages 243-271, July.
    Full references (including those not matched with items on IDEAS)

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Ahmad Alrazni Alshammari, Basheer Altarturi, Buerhan Saiti, Latifah Munassar, 2020. "The impact of exchange rate, oil price and gold price on the Kuwaiti stock market: a wavelet analysis," European Journal of Comparative Economics, Cattaneo University (LIUC), vol. 17(1), pages 31-54, June.
    2. Madaleno, Mara & Pinho, Carlos, 2014. "Wavelet dynamics for oil-stock world interactions," Energy Economics, Elsevier, vol. 45(C), pages 120-133.
    3. Godil, Danish Iqbal & Sarwat, Salman & Khan, Muhammad Kamran & Ashraf, Muhammad Sajjad & Sharif, Arshian & Ozturk, Ilhan, 2022. "How the price dynamics of energy resources and precious metals interact with conventional and Islamic Stocks: Fresh insight from dynamic ARDL approach," Resources Policy, Elsevier, vol. 75(C).
    4. Chang, Bisharat Hussain & Sharif, Arshian & Aman, Ameenullah & Suki, Norazah Mohd & Salman, Asma & Khan, Syed Abdul Rehman, 2020. "The asymmetric effects of oil price on sectoral Islamic stocks: New evidence from quantile-on-quantile regression approach," Resources Policy, Elsevier, vol. 65(C).
    5. Balcilar, Mehmet & Demirer, Rıza & Hammoudeh, Shawkat, 2019. "Quantile relationship between oil and stock returns: Evidence from emerging and frontier stock markets," Energy Policy, Elsevier, vol. 134(C).
    6. Dagher, Leila & El Hariri, Sadika, 2013. "The impact of global oil price shocks on the Lebanese stock market," Energy, Elsevier, vol. 63(C), pages 366-374.
    7. Ahmed, Walid M.A., 2017. "On the dynamic interactions between energy and stock markets under structural shifts: Evidence from Egypt," Research in International Business and Finance, Elsevier, vol. 42(C), pages 61-74.
    8. Jesus Cuauhtemoc Tellez Gaytan & Aqila Rafiuddin & Gyanendra Singh Sisodia & Gouher Ahmed & CH Paramaiah, 2023. "Pass-through Effects of Oil Prices on LATAM Emerging Stocks before and during COVID-19: An Evidence from a Wavelet -VAR Analysis," International Journal of Energy Economics and Policy, Econjournals, vol. 13(1), pages 529-543, January.
    9. Aqila Rafiuddin & Jennifer Daffodils & Jesus Cuauhtemoc Tellez Gaytan & Gyanendra Singh Sisodia, 2021. "Trend of Oil Prices, Gold, GCC Stocks Market during Covid-19 Pandemic: A Wavelet Approach," International Journal of Energy Economics and Policy, Econjournals, vol. 11(4), pages 560-572.
    10. Mohammad I. Elian & Khalid M. Kisswani, 2018. "Oil price changes and stock market returns: cointegration evidence from emerging market," Economic Change and Restructuring, Springer, vol. 51(4), pages 317-337, November.
    11. Nsisong Patrick Ekong & Daniel Wilson Ebong, 2016. "On the Crude Oil Price, Stock Market Movement and Economic Growth Nexus in Nigeria Evidence from Cointegration and Var Analysis," Asian Journal of Economic Modelling, Asian Economic and Social Society, vol. 4(3), pages 112-123, September.
    12. Zhang, Hao & Cai, Guixin & Yang, Dongxiao, 2020. "The impact of oil price shocks on clean energy stocks: Fresh evidence from multi-scale perspective," Energy, Elsevier, vol. 196(C).
    13. Jammazi, Rania, 2012. "Oil shock transmission to stock market returns: Wavelet-multivariate Markov switching GARCH approach," Energy, Elsevier, vol. 37(1), pages 430-454.
    14. Ben Cheikh, Nidhaleddine & Ben Naceur, Sami & Kanaan, Oussama & Rault, Christophe, 2021. "Investigating the asymmetric impact of oil prices on GCC stock markets," Economic Modelling, Elsevier, vol. 102(C).
    15. Muhammad Syafii Antonio & Aam S. Rusydiana & Wahyu Sugeng Imam Soeparno & Lina Nugraha Rani & Wahyu Ario Pratomo & Abdillah Arif Nasution, 2021. "The Impact of Oil Price and Other Macroeconomic Variables on The Islamic and Conventional Stock Index in Indonesia," International Journal of Energy Economics and Policy, Econjournals, vol. 11(5), pages 418-424.
    16. Jiranyakul, Komain, 2014. "Does oil price uncertainty transmit to the Thai stock market?," MPRA Paper 57262, University Library of Munich, Germany.
    17. El Hedi Arouri, Mohamed & Jouini, Jamel & Nguyen, Duc Khuong, 2011. "Volatility spillovers between oil prices and stock sector returns: Implications for portfolio management," Journal of International Money and Finance, Elsevier, vol. 30(7), pages 1387-1405.
    18. Aloui, Chaker & Hammoudeh, Shawkat & Hamida, Hela ben, 2015. "Global factors driving structural changes in the co-movement between sharia stocks and sukuk in the Gulf Cooperation Council countries," The North American Journal of Economics and Finance, Elsevier, vol. 31(C), pages 311-329.
    19. Salah A. Nusair & Jamal A. Al-Khasawneh, 2018. "Oil price shocks and stock market returns of the GCC countries: empirical evidence from quantile regression analysis," Economic Change and Restructuring, Springer, vol. 51(4), pages 339-372, November.
    20. Ali, Mohsin & Masih, Mansur, 2014. "Does Indian Stock Market Provide Diversification Benefits Against Oil Price Shocks? A Sectoral Analysis," MPRA Paper 58828, University Library of Munich, Germany.

    More about this item

    NEP fields

    This paper has been announced in the following NEP Reports:

    Statistics

    Access and download statistics

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:arx:papers:2309.00618. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a bibliographic reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: arXiv administrators (email available below). General contact details of provider: http://arxiv.org/ .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.