STRUCTRESIDS Procedure |
@StructResids converts standard VAR residuals into the equivalent structural innovations. If \(\bf{u}_t\) are the standard VAR residuals and the structural model is
(1) \({\bf{Fv}}_t = {\bf{u}}_t \)
then the procedure takes the VECT[SERIES] of \(\bf{u}\), plus the factor matrix \(\bf{F}\) and produces the VECT[SERIES] of the structural residuals \(\bf{v}\). @StructResids also offers the option of providing a direct set of weights to create the \(\bf{v}\) from \(\bf{u}\)
(2) \({\bf{v}}_t = {\bf{Wu}}_t \)
@StructResids( options ) u start end v
Parameters
u |
(input) VECT[SERIES] of VAR residuals |
start, end |
range to convert. By default, the common range of u. |
v |
(output) VECT[SERIES] of structural innovations |
Options
You need to use one and only one of FACTOR and WEIGHTS:
FACTOR=F matrix in the form (1) above.
WEIGHTS=W matrix in the form (2) above.
If \({\bf{F}}\) isn't a full \(n \times n\) matrix, then the covariance matrix of \({\bf{u}}\) is also needed to do compute the weight matrix which solves for \({\bf{v}}\) (the formula for the weight matrix is \({\bf{F'}}{\Sigma ^{ - 1}}\)). By default, that will be the standard %SIGMA matrix; if it's some other matrix, you can input it using the SIGMA option. The three forms are thus:
@StructResids(FACTOR=F) u start end v
@StructResids(WEIGHTS=W) u start end v
@StructResids(FACTOR=F,SIGMA=S) u start end v
where the first is used if \({\bf{F}}\) is a full \(n \times n\) factor of the covariance matrix, the second is used if you have a \(r \times n\) matrix of weights to construct the structural residuals from the VAR residuals, and the last is used if \({\bf{F}}\) is an \(n \times r\) part of a factorization.
Example
This is from the YUYPCOMPARE.RPF program in the Faust and Leeper(1997) replication. This uses a long-run restriction to identify aggregate demand (and aggregate supply) shocks from a two variable model with GDP and unemployment. The factor has the supply shock in column 1 and demand in column 2, so YUSHOCKS(1) will be the model's estimate of the supply shocks and YUSHOCKS(2) the demand shocks.
system(model=varmodel)
var gdpadjust uradjust
lags 1 to 8
det constant
end(system)
*
estimate(noprint,resids=yuresids)
*
compute factor=%bqfactor(%sigma,%varlagsums)
*
* Make sure that the two shocks have a positive impact on GDP (variable #1).
*
@impactsignflip factor ||+1,+1||
*
* Convert the VAR residuals to structural residuals
*
@structresids(factor=factor) yuresids / yushocks
Copyright © 2024 Thomas A. Doan