IDEAS home Printed from https://ideas.repec.org/a/gam/jrisks/v5y2017i4p62-d120204.html
   My bibliography  Save this article

An Analysis and Implementation of the Hidden Markov Model to Technology Stock Prediction

Author

Listed:
  • Nguyet Nguyen

    (Faculty of Mathematics and Statistics, Youngstown State University, 1 University Plaza, Youngstown, OH 44555, USA)

Abstract

Future stock prices depend on many internal and external factors that are not easy to evaluate. In this paper, we use the Hidden Markov Model, (HMM), to predict a daily stock price of three active trading stocks: Apple, Google, and Facebook, based on their historical data. We first use the Akaike information criterion (AIC) and Bayesian information criterion (BIC) to choose the numbers of states from HMM. We then use the models to predict close prices of these three stocks using both single observation data and multiple observation data. Finally, we use the predictions as signals for trading these stocks. The criteria tests’ results showed that HMM with two states worked the best among two, three and four states for the three stocks. Our results also demonstrate that the HMM outperformed the naïve method in forecasting stock prices. The results also showed that active traders using HMM got a higher return than using the naïve forecast for Facebook and Google stocks. The stock price prediction method has a significant impact on stock trading and derivative hedging.

Suggested Citation

  • Nguyet Nguyen, 2017. "An Analysis and Implementation of the Hidden Markov Model to Technology Stock Prediction," Risks, MDPI, vol. 5(4), pages 1-16, November.
  • Handle: RePEc:gam:jrisks:v:5:y:2017:i:4:p:62-:d:120204
    as

    Download full text from publisher

    File URL: https://www.mdpi.com/2227-9091/5/4/62/pdf
    Download Restriction: no

    File URL: https://www.mdpi.com/2227-9091/5/4/62/
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Andrew Ang & Geert Bekaert, 2002. "International Asset Allocation With Regime Shifts," The Review of Financial Studies, Society for Financial Studies, vol. 15(4), pages 1137-1187.
    2. Nguyet Nguyen & Dung Nguyen, 2015. "Hidden Markov Model for Stock Selection," Risks, MDPI, vol. 3(4), pages 1-19, October.
    3. Guidolin, Massimo & Timmermann, Allan, 2007. "Asset allocation under multivariate regime switching," Journal of Economic Dynamics and Control, Elsevier, vol. 31(11), pages 3503-3544, November.
    Full references (including those not matched with items on IDEAS)

    Citations

    Citations are extracted by the CitEc Project, subscribe to its RSS feed for this item.
    as


    Cited by:

    1. Hayet Soltani & Mouna Boujelbène Abbes, 2023. "The Predictive Power of Financial Stress on the Financial Markets Dynamics: Hidden Markov Model," Journal of Economics and Finance, Springer;Academy of Economics and Finance, vol. 47(1), pages 94-115, March.
    2. Anton Gerunov, 2023. "Stock Returns Under Different Market Regimes: An Application of Markov Switching Models to 24 European Indices," Economic Studies journal, Bulgarian Academy of Sciences - Economic Research Institute, issue 1, pages 18-35.
    3. Mojtaba Sedighi & Hossein Jahangirnia & Mohsen Gharakhani & Saeed Farahani Fard, 2019. "A Novel Hybrid Model for Stock Price Forecasting Based on Metaheuristics and Support Vector Machine," Data, MDPI, vol. 4(2), pages 1-28, May.
    4. De Gooijer, Jan G. & Henter, Gustav Eje & Yuan, Ao, 2022. "Kernel-based hidden Markov conditional densities," Computational Statistics & Data Analysis, Elsevier, vol. 169(C).
    5. Albert Cohen, 2018. "Editorial: A Celebration of the Ties That Bind Us: Connections between Actuarial Science and Mathematical Finance," Risks, MDPI, vol. 6(1), pages 1-3, January.

    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. Nguyet Nguyen, 2018. "Hidden Markov Model for Stock Trading," IJFS, MDPI, vol. 6(2), pages 1-17, March.
    2. Meenagh, David & Minford, Patrick & Peel, David, 2007. "Simulating stock returns under switching regimes - A new test of market efficiency," Economics Letters, Elsevier, vol. 94(2), pages 235-239, February.
    3. Jia Liu & John M. Maheu & Yong Song, 2024. "Identification and forecasting of bull and bear markets using multivariate returns," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 39(5), pages 723-745, August.
    4. Lee, Hsiang-Tai, 2022. "Regime-switching angular correlation diversification," Finance Research Letters, Elsevier, vol. 50(C).
    5. Bernardi, Mauro & Catania, Leopoldo, 2018. "Portfolio optimisation under flexible dynamic dependence modelling," Journal of Empirical Finance, Elsevier, vol. 48(C), pages 1-18.
    6. Erik Kole & Dick Dijk, 2017. "How to Identify and Forecast Bull and Bear Markets?," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 32(1), pages 120-139, January.
    7. Guidolin, Massimo & Hyde, Stuart, 2012. "Can VAR models capture regime shifts in asset returns? A long-horizon strategic asset allocation perspective," Journal of Banking & Finance, Elsevier, vol. 36(3), pages 695-716.
    8. Engsted, Tom & Pedersen, Thomas Q., 2012. "Return predictability and intertemporal asset allocation: Evidence from a bias-adjusted VAR model," Journal of Empirical Finance, Elsevier, vol. 19(2), pages 241-253.
    9. Kole, Erik & van Dijk, Dick, 2023. "Moments, shocks and spillovers in Markov-switching VAR models," Journal of Econometrics, Elsevier, vol. 236(2).
    10. Guidolin, Massimo & Hyde, Stuart, 2008. "Equity portfolio diversification under time-varying predictability: Evidence from Ireland, the US, and the UK," Journal of Multinational Financial Management, Elsevier, vol. 18(4), pages 293-312, October.
    11. Poshakwale, Sunil S. & Mandal, Anandadeep, 2016. "Determinants of asymmetric return comovements of gold and other financial assets," International Review of Financial Analysis, Elsevier, vol. 47(C), pages 229-242.
    12. Dias, José G. & Ramos, Sofia B., 2013. "A core–periphery framework in stock markets of the euro zone," Economic Modelling, Elsevier, vol. 35(C), pages 320-329.
    13. Branger, Nicole & Kraft, Holger & Meinerding, Christoph, 2009. "What is the impact of stock market contagion on an investor's portfolio choice?," Insurance: Mathematics and Economics, Elsevier, vol. 45(1), pages 94-112, August.
    14. Daniele Bianchi & Massimo Guidolin, 2014. "Can Linear Predictability Models Time Bull and Bear Real Estate Markets? Out-of-Sample Evidence from REIT Portfolios," The Journal of Real Estate Finance and Economics, Springer, vol. 49(1), pages 116-164, July.
    15. Guidolin, Massimo & Liu, Hening, 2016. "Ambiguity Aversion and Underdiversification," Journal of Financial and Quantitative Analysis, Cambridge University Press, vol. 51(4), pages 1297-1323, August.
    16. Branger, Nicole & Kraft, Holger & Meinerding, Christoph, 2014. "Partial information about contagion risk, self-exciting processes and portfolio optimization," Journal of Economic Dynamics and Control, Elsevier, vol. 39(C), pages 18-36.
    17. Nguyet Nguyen & Dung Nguyen, 2015. "Hidden Markov Model for Stock Selection," Risks, MDPI, vol. 3(4), pages 1-19, October.
    18. Thomas Q. Pedersen, 2015. "Predictable Return Distributions," Journal of Forecasting, John Wiley & Sons, Ltd., vol. 34(2), pages 114-132, March.
    19. Massimo Guidolin & Stuart Hyde, 2008. "Equity portfolio diversification under time-varying predictability and comovements: evidence from Ireland, the US, and the UK," Working Papers 2008-005, Federal Reserve Bank of St. Louis.

    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:gam:jrisks:v:5:y:2017:i:4:p:62-:d:120204. 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: MDPI Indexing Manager (email available below). General contact details of provider: https://www.mdpi.com .

    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.