## S3 method for class 'VECM':
logLik(object,r,...)
VECM
computed by VECM
.VECM
, but can be set differently by user.logLik
.VECM
was estimated with ML (Johansen) or 2OLS (Engle and Granger). When the model is estimated with ML, the LL is computed as in Hamilton (1994) 20.2.10 (p. 637):
When the model is estimated with 2OLS, the LL is computed as:
Where $\Sigma$ is the variance matrix of residuals from the the VECM model. There is hence no correspondance between the LL from the VECM computed with 2OLS or ML.
data(zeroyld)
data<-zeroyld
#Fit a VAR
vecm<-VECM(data, lag=1,r=1, estim="ML")
logLik(vecm)
Run the code above in your browser using DataLab