In trying to implement Mixture Markov Model, (see question here), I have extreme cases ( e.g. 0's in the Transition Probability Matrix). I have approached this with replacing 0 with 1e-17. However, I believe that such approximation might be breaking the algorithm, because in consequent steps I start seeing even smaller values by huge magnitute ( e.g. conditional posteriors in E-step are sometimes of magnitude 1e-321). This results from the likelihood formula, which multiplies the probabilities taken to powers of the number of occurrences of such transitions in each sequence.

With Markov mixture model I am trying to cluster a number of sequences, some of which might be very long (up to several hundred transitions). This also creates some extremalities (such as very small transition probabilities for some states for some sequences, if not 0 then 1e-20 or something similar).

Since I already make assumption that 1e-17 is an approximation of 0, any values that are less than this, would be meaningless. However, working with 0's is impossible because MAP log-likelihood value would be -Inf ( =log(0)).

Is there an approximation technique that is used for such cases? What is the best way to approximate 0's? I am working in R and there is a limit to R's precision (somewhere around 1e-400..). I am really at a loss.


More generally you should write in you transition matrix numbers that best describe confidence intervals for probabilities. I would suggest to use Laplace Smoothing - the main idea of it is just add small K for each possible transition and then recalculate transition matrix. Or if you have a really huge matrix with alot of sparcity you can try as first approach - just add 1 event to your 0-transition (ignoring other probabilities) .


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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