Detecting bearish and bullish markets in financial time series using hierarchical Hidden Markov models

Lennart Oelschläger*, Timo Adam

*Corresponding author for this work

Research output: Contribution to journalArticlepeer-review


Financial markets exhibit alternating periods of rising and falling prices. Stock traders seeking to make profitable investment decisions have to account for those trends, where the goal is to accurately predict switches from bullish to bearish markets and vice versa. Popular tools for modelling financial time series are hidden Markov models, where a latent state process is used to explicitly model switches among different market regimes. In their basic form, however, hidden Markov models are not capable of capturing both short- and long-term trends, which can lead to a misinterpretation of short-term price fluctuations as changes in the long-term trend. In this article, we demonstrate how hierarchical hidden Markov models can be used to draw a comprehensive picture of market behaviour, which can contribute to the development of more sophisticated trading strategies. The feasibility of the suggested approach is illustrated in two real-data applications, where we model data from the Deutscher Aktienindex and the Deutsche Bank stock. The proposed methodology is implemented in the R package fHMM, which is available on CRAN.
Original languageEnglish
Pages (from-to)107-126
Number of pages20
JournalStatistical Modelling
Issue number2
Early online date18 Aug 2021
Publication statusPublished - 1 Apr 2023


  • Decoding market behaviour
  • Hidden Markov models
  • Temporal resolution
  • Time series modelling
  • State-space models


Dive into the research topics of 'Detecting bearish and bullish markets in financial time series using hierarchical Hidden Markov models'. Together they form a unique fingerprint.

Cite this