make_matrices {dsem} | R Documentation |
Make path matrices
Description
Constructs path matrices for dynamic structural equation model (DSEM) using a vector of parameters and specification of the DSEM
Usage
make_matrices(beta_p, model, times, variables)
Arguments
beta_p |
vector parameters. |
model |
matrix or data.frame with the following columns, and one row per one-headed or two-headed arrow in the dynamic structural model:
|
times |
integer-vector of times to use when defining matrices |
variables |
character-vector listing variables |
Details
When length(times)
is T
and length(variables)
is J
,
make_matrices
returns matrices of dimension TJ \times TJ
representing
paths among vec(\mathbf{X})
where matrix \mathbf{X}
has dimension
T \times J
and vec
stacks columns into a single long vector
Value
A named list of matrices including:
- P_kk
The matrix of interactions, i.e., one-headed arrows
- G_kk
The matrix of exogenous covariance, i.e., two-headed arrows