Description Usage Arguments Details Value Examples
Simulate from conjugate N-IW posterior distribution
1 2 | bvar_conj_simulate(v_post, Omega_post_root, S_post, Phi_post, verbose = FALSE,
keep = 10)
|
v_post |
posterior nu, scalar |
Omega_post_root |
[k x k] 'root' of Omega posterior matrix |
S_post |
[m x m] posterior scale matrix for noise covariance |
Phi_post |
[k x m] posterior expected values for coefs |
verbose |
TRUE will show some debugging messages, FALSE by default |
keep |
number of simulations |
Simulate from conjugate N-IW posterior distribution
coda object with simulations
1 2 3 4 5 6 | data(Yraw)
dummy <- bvar_conj_lambda2dummy(Yraw, p = 2)
hyper <- bvar_conj_dummy2hyper(dummy$Y_cniw, dummy$X_cniw)
# these are priors but just for testing let's pretend that they are posteriors
post_sample <- bvar_conj_simulate(v_post = 10,
hyper$Omega_root, hyper$S, hyper$Phi)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.