% a simple markov chain example
states = ['s';'r'];
init = [0.5 0.5];
trans = [0.9 0.1;0.5 0.5];
[s,ss] = markovGenerate(10,init,trans,states);
[lik,loglik] = calcLikelihood(s,init,trans);
fprintf(1,'sequence = %s, lik = %.4f, loglik = %.4f \n',ss,lik,loglik);