hhsmmspec | R Documentation |
Specify a model of class "hhsmmspec"
using the model parameters
hhsmmspec(
init,
transition,
parms.emission,
sojourn = NULL,
dens.emission,
remission = NULL,
mstep = NULL,
semi = NULL
)
init |
vector of initial probabilities |
transition |
the transition matrix |
parms.emission |
the parameters of the emission distribution |
sojourn |
the sojourn distribution, which is one of the following cases:
|
dens.emission |
the probability density function of the emission |
remission |
the random sample generation from the emission distribution |
mstep |
the M step function for the EM algorithm |
semi |
a logical vector of length nstate: the TRUE associated states are considered as semi-markov |
a model of class "hhsmmspec"
Morteza Amini, morteza.amini@ut.ac.ir, Afarin Bayat, aftbayat@gmail.com
init = c(1, 0)
transition = matrix(c(0, 1, 1, 0), 2, 2)
parms.emission = list(mix.p = list(c(0.5, 0.5), 1),
mu = list(list(c(1, 2), c(5, 1)), c(2, 7)),
sigma = list(list(diag(2), 2 * diag(2)), 0.5 * diag(2)))
sojourn = list(lambda = 1, shift = 5, type = "poisson")
dens.emission = dmixmvnorm
remission = rmixmvnorm
mstep = mixmvnorm_mstep
semi = rep(TRUE,2)
model = hhsmmspec(init, transition, parms.emission, sojourn,
dens.emission, remission, mstep, semi)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.