Firstly I want to thank you for this tutorial, and for papers.

I want to use your tool in order to decide which Markov chain order will suit better for my data.

What im stuggling to understand is, how to determine mathematically the accuracy of single Markov chain Model (like first order.). Is correct to use Cross validation to predict the accuracy of my model? And are there any boundaries to decide if Model is accurate or it is not? ]]>

Suppose I want to calculate a simple row sum in a matrix using nested for loops but the matrix is a sparse matrix.Is there any difference in using the loops while using the sparse matrix? ]]>

Thank you for your great post! really Helpful. I am not really sure to follow the last part though.

How would you modify the following line to select row 3 and 4?

b = csr_matrix((a.data[a.indptr[3]:a.indptr[3+1]], a.indices[a.indptr[3]:a.indptr[3+1]], np.array([0,len(a.indices[a.indptr[3]:a.indptr[3+1]])])), shape=(1,n))

Many thanks.

]]>Can You help me which def should I call for the cross validation in Python, and how to use it?

Thanks ]]>