1st-order Markov Chain: The time value depends only on the value. Transition probability:

Probability of an instance :

To use this, you should make transition probability for all the classes.

Then,

In here, is called the threshold value. Its value highly depends on the circumstances of the problem. It can be based on the cost of misclassification, prior probabilities, or fixed at 0.