VARXLagCons {BigVAR} | R Documentation |
Construct a VAR or VARX lag matrix
Description
Construct a VAR or VARX lag matrix
Usage
VARXLagCons(Y, X = NULL, p, s = 0, oos = FALSE, contemp = FALSE)
Arguments
Y |
a |
X |
a |
p |
Endogenous Lag order |
s |
exogenous lag order (default zero) |
oos |
indicator as to whether the data should be constructed for out of sample prediction (i.e. last available entries of Y as final lags default FALSE) |
contemp |
indicator as to whether to use contemporaneous exogenous predictors (for example, if exogenous series become available before exogenous default FALSE). |
Details
This function is not required unless you which to design your own cross validation routine.
Value
list with two entries:
'Z'
kp+ms+1\times T-max(p,s)
VARX lag matrix'Y'adjusted
k\times T-max(p,s)
endogenous series
References
See page 15 of Lutkepohl, 'A New Introduction to Multiple Time Series Analysis
See Also
Examples
data(Y)
# construct VAR lag matrix with p=4
ZZ<-VARXLagCons(Y,X=NULL,p=4,s=0)