Description Usage Arguments Value See Also Examples
Returns the initial state probabilities from a HMM object.
The object has to be initialized with initparams
,
which generates a random initial state. The vector of probabilities
follows the same order as the states, so ptransition(model)[i]
is the
probability of state i
. Of course, the probabilities sum up to one.
1 2 3 4 |
x |
the HMM object. |
A numeric vector with the probabilities.
initparams, fit, nstates, initsteady
1 2 3 4 5 6 | model <- HMM(2)
model <- addtransition(model,c(1,2))
model <- addtransition(model,c(2,1))
model <- initparams(model)
istates(model)
sum(istates(model)) # should be one
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.