Description Usage References See Also Examples
View source: R/simulate_var.R
Simulate VAR
1
sim_var(Acoef, innov = NULL, varcov = NULL, nrep = 200)
https://github.com/MatthieuStigler/tsDyn/blob/a6aa2ebc041e448b3eb8598ffd117a83cfe316e5/tsDyn/R/VAR.sim.R
mlvar::simulateVAR tsDyn::VAR.sim
1 2 3 4 5 6 7 8 9
obj <- varm(varm::spec(econdata::sw2001[,-1], .endo_lags = 4)) Acoef <- coefficients(obj) set.seed(123) dyn <- tsDyn:::VAR.sim(t(Acoef), n = 200, lag = 4, include = "const") plot.ts(dyn) set.seed(123) ab <- gen_var(Acoef, nrep = 200) plot.ts(ab) waldo::compare(dyn, ab)
Add the following code to your website.
REMOVE THIS Copy to clipboard
For more information on customizing the embed code, read Embedding Snippets.