AdaemmerP / lpirfs

40 stars 21 forks source link

Reason for cumul_mult only being in iv() functions #41

Closed carlmroth closed 5 months ago

carlmroth commented 6 months ago

Hi Philipp, Thanks for the very useful package. I wonder about the reason that the option cumul_mult was in the update only incorporated in lp_lin_iv() and lp_nl_iv() but not in the standard lp_lin() and lp_nl() functions, where the shock matrix is obtained via the Cholesky decomposition. Thus, I am wondering whether it would be sufficient to update in lp_lin() the definition of yy as below or if it is not as straightforward and would need to be incorporated already in Cholesky decomposition: yy <- y_lin[h:dim(y_lin)[1], ], for example, in row 353 of lp_lin() to yy <- dplyr::lead(y_lin, (h - 1)) - dplyr::lag(y_lin, 1), starting from 438 in lp_lin_iv() Thanks in advance.

AdaemmerP commented 5 months ago

I have implemented these options based on the literature. To be honest, I am not even sure why "cumul_mult" is sometimes used, as it simply shifts the y-variable and should not affect the beta coefficients, hence the impulse responses. I am not sure about lp_lin() and lp_nl(). For now I would leave them as they are due to time restraints. For what do you need that option?

carlmroth commented 5 months ago

Thanks for your thoughts on this. Indeed, I see this very often implemented in the economics literature. For me it is at the moment not obvisous if in the case where the shock matrix is obtained via Cholesky instead of an ex ante specified shock this has any impact when using the "cumul_mult" approach. Thus, I thought maybe you had some more reflection on this and whether it was a deliberat choice to only use it for the iv() functions with already identified shocks.

AdaemmerP commented 5 months ago

I will close this issue then.