par: An object of class fHMM_parameters, which is a list
of model parameters.
controls: Either a list or an object of class fHMM_controls.
The list can contain the following elements, which are described in more detail below:
hierarchy, defines an hierarchical HMM,
states, defines the number of states,
sdds, defines the state-dependent distributions,
horizon, defines the time horizon,
period, defines a flexible, periodic fine-scale time horizon,
data, a list of controls that define the data,
fit, a list of controls that define the model fitting
Either none, all, or selected elements can be specified.
Unspecified parameters are set to their default values.
Important: Specifications in controls always override individual specifications.
use_parameter_labels: Either TRUE to label the parameters or FALSE, if not (this can save computation time).
parUncon: An object of class parUncon, which is a numericvector
with identified and unconstrained model parameters in the following order:
non-diagonal transition probabilities gammasUncon
expectations muUncon
standard deviations sigmaUncon (if any)
degrees of freedom dfUncon (if any)
fine-scale parameters for each coarse-scale state, in the same order (if any)
numerical_safeguard: Either TRUE or FALSE, determining whether to apply the following small corrections to boundary parameters to improve numerical performance when calculating and optimizing the likelihood function:
transition probabilities equal to 0 or 1 are shifted towards the center by 1e-3
standard deviations and degrees of freedom are bounded above by 100
parCon: An object of class parCon, which is a numericvector
with identified (and constrained) model parameters in the following order:
non-diagonal transition probabilities gammasCon
expectations muCon
standard deviations sigmaCon (if any)
degrees of freedom dfCon (if any)
fine-scale parameters for each coarse-scale state, in the same order (if any)
muCon, muUncon: A vector of (un-) constrained expected values.
link: Either TRUE or FALSE, determining whether to apply the link function.
prefix: A character prefix for labeling the parameters.
sigmaCon, sigmaUncon: A vector of (un-) constrained standard deviations.
dfCon, dfUncon: A vector of (un-) constrained degrees of freedom.
gammasCon, gammasUncon: A vector of (un-) constrained non-diagonal transition probabilities.
dim: An integer, the dimension of the transition probability matrix.
Returns
For par2parUncon: a vector of unconstrained model parameters.
For parUncon2parCon: a vector of constrained model parameters.
For parCon2par: an object of class fHMM_parameters.
For par2parCon: a vector of constrained model parameters.
For parCon2parUncon: a vector of unconstrained model parameters.
For parUncon2par: an object of class fHMM_parameters.
For muCon2muUncon: a vector of unconstrained expected values.
For muUncon2muCon: a vector of constrained expected values.
For sigmaCon2sigmaUncon: a vector of unconstrained standard deviations.
For sigmaUncon2sigmaCon: a vector of constrained standard deviations.
For dfCon2dfUncon: a vector of unconstrained degrees of freedom.
For dfUncon2dfCon: a vector of constrained degrees of freedom.
For Gamma2gammasCon: a vector of constrained non-diagonal matrix elements (column-wise).
For Gamma2gammasUncon: a vector of unconstrained non-diagonal matrix elements (column-wise).
For gammasCon2Gamma: a transition probability matrix.
For gammasCon2gammasUncon: a vector of unconstrained non-diagonal elements of the transition probability matrix.
For gammasUncon2Gamma: a transition probability matrix.
For gammasUncon2gammasCon: a vector of constrained non-diagonal elements of a transition probability matrix.