Closed dcuoliveira closed 3 years ago
Im getting an issue of absence of "n_reps" variable when estimting the model, although i have it as an input in my prior.
Below you can see the code i tried:
rm(list=ls()) library('mfbvar') data("mf_usa")
mfbvar_prior = set_prior(Y = mf_usa, n_lags = 4, n_reps = 1000)
prior_intervals = matrix(c(1, 3, 4, 8, 1, 3), ncol = 2, byrow = TRUE) moments = interval_to_moments(prior_intervals) mfbvar_prior = update_prior(mfbvar_prior, d = "intercept", prior_psi_mean = moments$prior_psi_mean, prior_psi_Omega = moments$prior_psi_Omega) plot(mfbvar_prior) mfbvar_prior = update_prior(mfbvar_prior, n_fcst = 24) summary(mfbvar_prior)
mod_ss_iw = estimate_mfbvar(pmfbvar_prior = mfbvar_prior, prior = "ss", variance = "iw")
and the error:
Error in mget(names(formals())[names(formals()) != "..."], sys.frame(sys.nframe())) : argument "n_reps" is missing
That is because you have typo:
mod_ss_iw = estimate_mfbvar(pmfbvar_prior = mfbvar_prior,
should be
mod_ss_iw = estimate_mfbvar(mfbvar_prior = mfbvar_prior,
Im getting an issue of absence of "n_reps" variable when estimting the model, although i have it as an input in my prior.
Below you can see the code i tried:
rm(list=ls()) library('mfbvar') data("mf_usa")
mfbvar_prior = set_prior(Y = mf_usa, n_lags = 4, n_reps = 1000)
prior_intervals = matrix(c(1, 3, 4, 8, 1, 3), ncol = 2, byrow = TRUE) moments = interval_to_moments(prior_intervals) mfbvar_prior = update_prior(mfbvar_prior, d = "intercept", prior_psi_mean = moments$prior_psi_mean, prior_psi_Omega = moments$prior_psi_Omega) plot(mfbvar_prior) mfbvar_prior = update_prior(mfbvar_prior, n_fcst = 24) summary(mfbvar_prior)
mod_ss_iw = estimate_mfbvar(pmfbvar_prior = mfbvar_prior, prior = "ss", variance = "iw")
and the error:
Error in mget(names(formals())[names(formals()) != "..."], sys.frame(sys.nframe())) : argument "n_reps" is missing