simHMM | R Documentation |
Simulates a path of states and observations for a given Hidden Markov Model.
simHMM(hmm, length)
hmm |
A Hidden Markov Model. |
length |
The length of the simulated sequence of observations and states. |
Dimension and Format of the Arguments.
A valid Hidden Markov Model, for example instantiated by initHMM
.
The function simHMM
returns a path of states and associated observations:
states |
The path of states. |
observations |
The sequence of observations. |
Lin Himmelmann <hmm@linhi.com>, Scientific Software Development
See initHMM
for instantiation of Hidden Markov Models.
# Initialise HMM hmm = initHMM(c("X","Y"),c("a","b","c")) # Simulate from the HMM simHMM(hmm, 100)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.