tidyMacro
  • Home
  • FAQ
  1. Main
  • Main
  • Short-run restrictions
  • Long-run restrictions
  • Mixed restrictions
  • External Instruments and Weak IV
  • Noninvertible shocks
  • Sign restrictions
  • Narrative restrictions
  • Sign restrictions and External instruments
  • Internal instruments
  • Heteroskedasticity
  • LP Primer
  • LP Syntax Primer
  • LP with Exogenous Shocks and IV
  • LP Panel
  • LP DID

On this page

  • Functionality
  • Models - Identification - Decompositions
    • 📚 How to Cite
  • Installation
  • References
  • Edit this page
  • Report an issue

Home

High-Performance Vector Autoregressions and Local Projections in R

Welcome to the website of tidyMacro!

tidyMacro is an R package for fast estimation and identification of Structural Vector Autoregressions (VAR) and local projections via C++ (Rcpp/RcppArmadillo).

Functionality

  • Fast VAR & VARX reduced form estimations
  • Local projections estimations with clean syntax, support for macros
  • Zero dependency on other packages. Ground up written in C++. All visualizations made with ggplot2 in R.
  • Publication-ready plots out of the box. Each plot is a ggplot2 object, can be ex post customized
  • The package comes with a proper theme
  • Parallel bootstrap computations via OpenMP for maximum speed.
  • Excellent documentation with detailed examples for every function
  • Import data via tidyverse, clean, modify and then supply your final data piping as matrix for Armadillo calculations
  • Example data sets for each replication via already transformed data

Models - Identification - Decompositions

  1. Identification via short-run / recursive ordering ✅

    • Impulse response functions ✅
      • Residual based bootstraps
      • Wild bootstraps
    • Bias corrected impulse Response functions ✅
    • Variance Decomposition ✅
    • Historical Decomposition ✅
    • Replication: Bloom (2009)
  2. Identification via long run restrictions

    • Impulse response functions ✅
    • Bias corrected impulse Response functions ✅
    • Variance Decomposition ✅
    • Replication 1: Galí (1999)
    • Replication 2: Beaudry and Portier (2014)
  3. Identification via external instruments (Proxy-SVAR) ✅

    • Impulse Response functions ✅
      • Moving block bootstraps
    • Forecast error variance Decomposition ✅
    • Historical Decomposition ✅
    • First Stage F-stats ✅
    • Recovering the shock series ✅
      • Unit normalization
      • One SD normalization
    • Weak IV Robust IRF ✅
      • Delta method
      • Anderson-Rubin
    • Replication: Känzig (2021)
    • External instrument SVAR analysis for noninvertible shocks following Forni et al. (2022) ✅
      • Invertibility test ✅
      • Recoverability test ✅
      • Calculate IRF, HD, FEVD and relative IRF if none. ✅
      • Replication: Forni et al. (2022) using a small VAR using Gertler and Karadi (2015) instrument and data
  4. Identification via Internal instruments ✅

    • Adding instrument to VAR as the first variable, then IRF identified recursively
    • Other options in short run / recursive identification apply here
    • Replication: Känzig (2021)
  5. Identification via Heteroskedasticity following Rigobon (2003) ✅

    • Impulse Response functions ✅
    • Replication: Känzig (2021)
  6. Identification via Sign, Narrative and Zero Restrictions ✅

    • Impulse response functions ✅
    • Historical Decomposition (Fry-Pagan draw) ✅
    • Narrative restrictions
      • Rejection sampling (VAR Toolbox convention) ✅
      • Optional ADRR importance reweighting ✅
    • Combined with external instruments (sign+IV)
      • Single instrument
      • Multiple instruments, jointly-identified shocks
    • First-stage F-stats and R² for the instrumented equation(s) ✅
    • Replication 1: Uhlig (2005) (sign only)
    • Replication 2: Antolín-Díaz and Rubio-Ramírez (2018) (sign + narrative, Volcker 1979)
    • Replication 3: Arias et al. (2019) (sign + single-instrument IV)
    • Replication 4: Cesa-Bianchi and Sokol (2022) (sign + two-instrument IV, US financial shock)
  7. Identification via Non-Gaussianity ⛔

  8. Local Projections ✅

    • Local projections with Exogenous Shocks
      • Replicaion: Jorda and Taylor (2025) ✅
    • Local projections IV
      • Replication: Jorda and Taylor (2025) ✅
    • Panel Local projections
      • Replication: Almuzara and Sancibrián (2024) ✅
    • Local Projections Difference in Differences ✅
      • Replication: Dube et al. (2025)
    • State Dependent Local projections ⛔

📚 How to Cite

WarningPlease cite this work as:

Ciftci, Muhsin (2026). tidyMacro: A Fast, Tidy Toolkit for Applied Macroeconometrics. Available at SSRN: https://papers.ssrn.com/sol3/papers.cfm?abstract_id=7150339

or in LaTeX:

@article{ciftci2026tidymacro,
  title   = {tidyMacro: A Fast, Tidy Toolkit for Applied Macroeconometrics},
  author  = {Ciftci, Muhsin},
  year    = {2026},
  journal = {SSRN Electronic Journal},
  url     = {https://papers.ssrn.com/sol3/papers.cfm?abstract_id=7150339}
}

Installation

# install.packages("devtools")
devtools::install_github("muhsinciftci/tidyMacro")
Back to top

References

Almuzara, Martı́n, and Vı́ctor Sancibrián. 2024. “Micro Responses to Macro Shocks.” FRB of New York Staff Report, no. 1090.
Antolín-Díaz, Juan, and Juan F. Rubio-Ramírez. 2018. “Narrative Sign Restrictions for SVARs.” American Economic Review 108 (10): 2802–29.
Arias, Jonas E., Dario Caldara, and Juan F. Rubio-Ramírez. 2019. “The Systematic Component of Monetary Policy in SVARs: An Agnostic Identification Procedure.” Journal of Monetary Economics 101: 1–13. https://doi.org/10.1016/j.jmoneco.2018.07.011.
Beaudry, Paul, and Franck Portier. 2014. “News-Driven Business Cycles: Insights and Challenges.” Journal of Economic Literature 52 (4): 993–1074. https://doi.org/10.1257/jel.52.4.993.
Bloom, Nicholas. 2009. “The Impact of Uncertainty Shocks.” Econometrica 77 (3): 623–85. https://doi.org/10.3982/ECTA6248.
Cesa-Bianchi, Ambrogio, and Andrej Sokol. 2022. “Financial Shocks, Credit Spreads, and the International Credit Channel.” Journal of International Economics 135: 103543. https://doi.org/10.1016/j.jinteco.2021.103543.
Dube, Arindrajit, Daniele Girardi, Òscar Jordà, and Alan M. Taylor. 2025. “A Local Projections Approach to Difference-in-Differences.” Journal of Applied Econometrics 40 (7): 741–58. https://doi.org/10.1002/jae.70000.
Forni, Mario, Luca Gambetti, and Giovanni Ricco. 2022. External Instrument SVAR Analysis for Noninvertible Shocks. https://warwick.ac.uk/fac/soc/economics/research/workingpapers/2022/twerp_1444_-_ricco.pdf.
Galí, Jordi. 1999. “Technology, Employment, and the Business Cycle: Do Technology Shocks Explain Aggregate Fluctuations?” American Economic Review 89 (1): 249–71. https://doi.org/10.1257/aer.89.1.249.
Gertler, Mark, and Peter Karadi. 2015. “Monetary Policy Surprises, Credit Costs, and Economic Activity.” American Economic Journal: Macroeconomics 7 (1): 44–76. https://doi.org/10.1257/mac.20130329.
Jorda, Oscar, and Alan M. Taylor. 2025. “Local Projections.” Journal of Economic Literature 63 (1): 59–110. https://doi.org/10.1257/jel.20241521.
Känzig, Diego R. 2021. “The Macroeconomic Effects of Oil Supply News: Evidence from OPEC Announcements.” American Economic Review 111 (4): 1092–125. https://doi.org/10.1257/aer.20190964.
Rigobon, Roberto. 2003. “Identification Through Heteroskedasticity.” The Review of Economics and Statistics 85 (4): 777–92. https://doi.org/10.1162/003465303772815727.
Uhlig, Harald. 2005. “What Are the Effects of Monetary Policy on Output? Results from an Agnostic Identification Procedure.” Journal of Monetary Economics 52 (2): 381–419.
Short-run restrictions

© 2025 Muhsin Ciftci · Goethe University Frankfurt

 
  • Edit this page
  • Report an issue

This page is built with Quarto.