I am trying to use the R package "urca". It has functions cajorls
and cajools
, which do ordinary least squares (OLS) regression of restricted and unrestricted vector error correction model (VECM) respectively. Both functions take in the VECM estimated using Johansen procedure and return the regression parameters and cointegrating vectors.
I do not understand, why is there a need to do OLS regression of VECM? Using Johansen test on the data (by calling ca.jo
) will give me the cointegrating vectors. What is the difference between cointegrating vectors of VECM and OLS regression of VECM?
Best Answer
Well
ca.jo
will give you the parameters for the long-run cointegrating relationship(s), but not the error correction/lags parameters, which are obtained by thecajools
. Note that for alternative, slightly more direct way, you can also use the functionVECM
from package "tsDyn".The reason for calling these function "OLS" is that, once your ECT(s) have been obtained by maximum-likelihood, the ML estimator for the other parameters is equivalent to a OLS regression, conditional on the ML parameters for the cointegrating relationship.