I am working on a prototype framework.

Basically I need to generate a model or profile for each individual's lifestyle based on some sensor data about him/her, such as GPS, motions, heart rate, surrounding environment readings, temperature etc.

The proposed model or profile is a knowledge representation of an individual's lifestyle pattern. Maybe a graph with probabilities.

I am thinking to use Hidden Markov Model to implement this. As the states in HMM can be Working, Sleeping, Leisure, Sport and etc. Observations can be a set of various sensor data.

My understanding of HMM is that next state S(t) is only depends on previous one state S(t-1). However in reality, a person's activity might depends on previous n states. Is it still a good idea to use HMM? Or should I use some other more appropriate models? I have seen some work on second order and multiple order of Markov Chains, does it also apply HMM?

I really appreciate if you can give me a detailed explanation.


  • 4
    $\begingroup$ You can always construct a (standard) Markov model out of the vectors $X(t) = (S(t-n+1), S(t-n+2), \ldots, S(t))$: now each state $X(t)$ depends only on the values found in $X(t-1)$ and you're off and running. $\endgroup$
    – whuber
    Commented Mar 19, 2013 at 19:24
  • 1
    $\begingroup$ Of course, @whuber's approach multiplies the dimension of the state space by $n$, which might cause problems in practice. You might also be interested in using conditional random fields, which are closely related to HMMs but make it easier to have dependencies further back in the state history. $\endgroup$
    – Danica
    Commented Mar 19, 2013 at 20:22

1 Answer 1


If you have a lot of sensors with possibly noisy data that you want to correlate to an unknown underlying state, this seems to be a classic use case for a Kalman filter instead of a higher order Markov model. Here is one tutorial of many; Google will provide much more help. Hope this redirect helps you.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.