sim_mniw {bvhar} | R Documentation |
Generate Normal-IW Random Family
Description
This function samples normal inverse-wishart matrices.
Usage
sim_mniw(num_sim, mat_mean, mat_scale_u, mat_scale, shape)
Arguments
num_sim |
Number to generate |
mat_mean |
Mean matrix of MN |
mat_scale_u |
First scale matrix of MN |
mat_scale |
Scale matrix of IW |
shape |
Shape of IW |
Details
Consider (Y_i, \Sigma_i) \sim MIW(M, U, \Psi, \nu)
.
Generate upper triangular factor of
\Sigma_i = C_i C_i^T
in the upper triangular Bartlett decomposition.Standard normal generation: n x k matrix
Z_i = [z_{ij} \sim N(0, 1)]
in row-wise direction.Lower triangular Cholesky decomposition:
U = P P^T
-
A_i = M + P Z_i C_i^T
Value
List of MN and IW matrices. Multiple samples are column-stacked.
[Package bvhar version 2.0.1 Index]