Skip to content

Commit

Permalink
comment about notations
Browse files Browse the repository at this point in the history
  • Loading branch information
adamwang15 committed Jul 16, 2024
1 parent b26a265 commit b140100
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ data(monetary)
# contractionary monetary policy shock
sign_irf = matrix(NA, 6, 6)
sign_irf[, 1] = c(NA, -1, -1, NA, -1, 1)
sign_irf = array(sign_irf, dim = c(6, 6, 5))
sign_irf = array(sign_irf, dim = c(6, 6, 6))

# in October 1979
sign_narrative = rbind(c(1, 1, NA, 1, 166, 0), # is positive
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ data(monetary)
# contractionary monetary policy shock
sign_irf = matrix(NA, 6, 6)
sign_irf[, 1] = c(NA, -1, -1, NA, -1, 1)
sign_irf = array(sign_irf, dim = c(6, 6, 5))
sign_irf = array(sign_irf, dim = c(6, 6, 6))

# in October 1979
sign_narrative = rbind(c(1, 1, NA, 1, 166, 0), # is positive
Expand Down
10 changes: 9 additions & 1 deletion src/bsvars_sign.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@ using namespace Rcpp;
using namespace arma;


/***
All notations in the C++ code except for compute.cpp and forecast_bsvarSIGNs.cpp
are consistent with the notations in the papers:
Antolín-Díaz and Rubio-Ramírez (2018) and Arias, Rubio-Ramírez and Waggoner (2018)
which are different from the notations in the R code.
***/


// [[Rcpp::interfaces(cpp)]]
// [[Rcpp::export]]
Rcpp::List bsvar_sign_cpp(
Expand Down Expand Up @@ -47,7 +55,7 @@ Rcpp::List bsvar_sign_cpp(
if (show_progress) {
Rcout << "**************************************************|" << endl;
Rcout << " bsvarSIGNs: Bayesian Structural VAR with zero, |" << endl;
Rcout << " sign and narrative restrictions |" << endl;
Rcout << " sign and narrative restrictions |" << endl;
Rcout << "**************************************************|" << endl;
// Rcout << " Gibbs sampler for the SVAR model |" << endl;
// Rcout << "**************************************************|" << endl;
Expand Down

0 comments on commit b140100

Please sign in to comment.