mchain | R Documentation |
Simulating a Markov Chain
mchain(n = 10, x0 = 2, P)
n |
number of generated points MC |
x0 |
initial states |
P |
transition matrix |
P1=rbind(c(3,1)/4, c(3,2)/5) mchain(10, 2, P1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.