Learn R Programming

gmvarkit (version 1.1.1)

check_constraints: Check the constraint matrix has the correct form

Description

check_constraints checks that the constraints are correctly set

Usage

check_constraints(p, M, d, constraints = NULL)

Arguments

p

a positive integer specifying the autoregressive order of the model.

M

a positive integer specifying the number of mixture components.

d

number of time series in the system.

constraints

a size \((Mpd^2 x q)\) constraint matrix \(C\) specifying general linear constraints to the autoregressive parameters. We consider constraints of form (\(\phi\)\(_{1}\)\(,...,\)\(\phi\)\(_{M}) = \)\(C \psi\), where \(\phi\)\(_{m}\)\( = (vec(A_{m,1}),...,vec(A_{m,p}) (pd^2 x 1), m=1,...,M\) contains the coefficient matrices and \(\psi\) \((q x 1)\) contains the constrained parameters. For example, to restrict the AR-parameters to be the same for all regimes, set \(C\)= [I:...:I]' \((Mpd^2 x pd^2)\) where I = diag(p*d^2). Ignore (or set to NULL) if linear constraints should not be employed.

Value

Checks the constraint matrix C and throws an error if something is wrong.

Details

If is.null(constraints), then this function doesn't do anything.