nk027 / bvar

Toolkit for the estimation of hierarchical Bayesian vector autoregressions. Implements hierarchical prior selection for conjugate priors in the fashion of Giannone, Lenza & Primiceri (2015). Allows for the computation of impulse responses and forecasts and provides functionality for assessing results.
https://cran.r-project.org/package=BVAR
Other
50 stars 21 forks source link

IRF colour #77

Closed Abhayprag closed 2 years ago

Abhayprag commented 2 years ago

Hello is there a way to darken and broaden the impulse response with a colour other than black? For confidence interval, I am able to change the colour and shade the area as given in the codes. But please let me know is there any way i can change the colur of the impulse response IR

nk027 commented 2 years ago

Hey @Abhayprag! You mean the line inbetween, i.e. the median respone? There's no way to set this manually, but you can

  1. Plot over it with lines(y, col = 2) using the median response of your choice (in irf(x)$quants["50%", i, , j])
  2. Use the BVARverse package (or the object) to get the data and plot it manually (with base or ggplot2) Hope that helps!
Abhayprag commented 2 years ago

Thanks for your response. Yes, I was referring to the line in between i.e median response.

Regards