R/trmat.depmix.fitted.R

trmat <- function(d) {
	M <- attributes(d)$nstates
  Mat <- matrix(0, M, M)
  for (i in 1:M) {
		for (j in 1:M) {
		  Mat[i, j] <- (attributes(d)$transition[[i]])@parameters$coefficients[j]
	  } 
	} 
  return (Mat)
}

Try the MmgraphR package in your browser

Any scripts or data that you put into this service are public.

MmgraphR documentation built on May 2, 2019, 6:49 p.m.