Hi everyone,
I'm using the svars
package to build an SVAR model. I'm curious to find out how to impose long-run restrictions on the svar object that I have in my example below (similar to the seminal Blanchard and Quah paper - https://uh.edu/~bsorense/BlanchardQuah1989.pdf). I essentially would like to restrict the long-run impact of GDP's response from a CPI shock to zero.
In the vars
package, I know that this could be done like this (svar_object <- BQ(var_object)
),
however I'm unsure of how to achieve a similar effect within the svars
package. Is there perhaps a way in which I could pass a restriction matrix as an argument within the code I've included below to do this? Or any other suggestions are also welcome!
TIA!
# Load Packages
library(tidyverse)
library(svars)
# Load snippet of dataset
data <- structure(c(-1.87308398729904, 2.290631067509, 0.993462708465565,
-1.29041209029221, 1.12545485962681, -2.636526517961, 1.64791593479841,
-0.127800586695059, -0.649131035554795, -1.41838122120497, -0.0727559182898574,
2.61173864035165, 0.408195006166245, 2.14851460203356, -3.43206431417578,
-3.21097438990066, -0.633222142832857, 3.62032490350241, -1.88466472673507,
3.1882672460176, -6.25889275693812, -5.63387155573629, -2.47686181080518,
-0.00946230989793406, 1.15917422619178, 1.26429447879497, 0.986332225049047,
2.41168238340004, 1.84115722165812, 1.41639006961984, 1.35342674612451,
2.79543996486087, 0.605266622518563, 0.554959915380682, 1.07421168196309,
1.2403520539725, 0.862800885835391, 1.26464488451186, 1.75852063191533,
0.546966935763926, 0.534163056633208, 0.63109068920264, 0.935286647736344,
0.159975810472712, 0.208743967794067, 0.973862299523898), .Dim = c(23L,
2L), .Dimnames = list(NULL, c("GDP", "CPI")), index = structure(c(1420070400,
1427846400, 1435708800, 1443657600, 1451606400, 1459468800, 1467331200,
1475280000, 1483228800, 1491004800, 1498867200, 1506816000, 1514764800,
1522540800, 1530403200, 1538352000, 1546300800, 1554076800, 1561939200,
1569888000, 1577836800, 1585699200, 1593561600), tzone = "UTC", tclass = "Date"), class = c("xts",
"zoo"))
# Create VAR model
var.model <- data %>% VAR(.,p=1,type = 'cons',season=NULL)
# Create SVAR model by Cholesky Decomposition
svar.model <- id.chol(var.model, order_k = c('GDP','CPI'))