Description Usage Arguments Value
This function fits data with an HMM by maximizing the likelihood estimate given initial gamma parameters.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | gam0_fit_hmm(
x,
design,
num_states,
num_variables,
num_subjects,
num_covariates,
alpha0,
theta0,
zweight0,
beta0,
delta0,
state_dep_dist_pooled = FALSE,
iterlim = 100,
steptol = 1e-06,
hessian = FALSE,
print.level = 0
)
|
x |
The data to be fit with an HMM in the form of a 3D array. The first index (row) corresponds to time, the second (column) to the variable number, and the third (matrix number) to the subject number. |
design |
A list of design matrices for each subject with each row indicating the time and each column indicating the value of the covariate. |
num_states |
The number of states in the desired HMM. |
num_variables |
The number of variables in the data. |
num_subjects |
The number of subjects/trials that generated the data. |
num_covariates |
The number of covariates in the data that the transition probability matrix depends on. |
alpha0 |
The starting values for the means of the gamma distributed
state dependent distributions of the HMM. |
theta0 |
The starting values for the standard deviations of the
gamma distributed state dependent distributions of the HMM. |
beta0 |
A matrix of the initial regression coefficients for the effect
of the covariates on the transition probability matrices |
delta0 |
A list with each element being the starting initial state distribution vector of the HMM for the subject corresponding to that index. |
state_dep_dist_pooled |
A logical variable indiacting whether the
state dependent distribution parameters |
iterlim |
A value indicating the number of iterations |
hessian |
A logical variable indicating whether to compute the hessian at the minimum. |
@param |
zweight0 The starting values for the weights of the zero
inflated portion of the gamma distributions. |
A list of parameters that specify the fitted gamma HMM.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.