Quantcast
Channel: Recent Questions - Stack Overflow
Viewing all articles
Browse latest Browse all 11661

transition probability matrix between the metastable states

$
0
0

I have calculated the transition matrix of a Markov state model with four metastable states. I would like to know the probability of transition between metastable states, for which I think I should obtain a 4x4 matrix.

I have tried to obtain said matrix with this code, but it turns out that in some entries of that matrix values ​​greater than 1 appear, which seems strange to me:

nstates = 4transition_matrix_meta = np.zeros((nstates, nstates))for i in range(nstates):for j in range(nstates):

    pi_i = msm.pi[msm.metastable_sets[i]].sum()      T_i_to_j = msm.transition_matrix[msm.metastable_sets[i]][:,               msm.metastable_sets[j]]    P_i_to_j = pi_i * T_i_to_j.sum()    transition_matrix_meta[i, j] = P_i_to_j

print(transition_matrix_meta)

Is my code correct?


Viewing all articles
Browse latest Browse all 11661

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>