mar_hmm_pn2pw: Transform multivariate autoregressive natural parameters to...

View source: R/multivariate_autoregressive_hmm_functions.R

mar_hmm_pn2pwR Documentation

Transform multivariate autoregressive natural parameters to working parameters

Description

mu and phi do not need to be transformed, as there are no constraints. We only need to transform diagonal elements of sigma, since there are no constraints on the covariances. Include only the lower triangular and diagional elements of the sigma matrix, since covariance matrices must be symmetric.

Usage

mar_hmm_pn2pw(m, mu, sigma, gamma, phi, delta = NULL, stationary = TRUE)

Arguments

m

Number of states

mu

List of vectors of length m, means for white noise in each state dependent distribution

sigma

List of matrices of size m x m, covariance matrices for each state dependent distribution

gamma

Transition probabiilty matrix, size m x m

phi

List of k x (k x q) matrices, containing the autoregressive parameters. Each matrix corresponds to a state. The first k x k entries are the parameters for index i - 1, and so on up to index i - q.

delta

Optional, vector of length m containing initial distribution

stationary

Boolean, whether the HMM is stationary or not

Value

Vector of working parameters


longjess/hornsharkHMM documentation built on June 15, 2022, 11:32 p.m.