Learn R Programming

tsDyn (version 0.9-44)

logLik.VECM: Extract Log-Likelihood

Description

Log-Likelihood method for VECM models.

Usage

# S3 method for VECM
logLik(object, r, ...)

Arguments

object

object of class VECM computed by VECM.

r

The cointegrating rank. By default the rank specified in the call to VECM, but can be set differently by user.

additional arguments to logLik.

Value

Log-Likelihood value.

Details

The Log-Likelihood is computed in two dfferent ways, depending on whether the 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):

$$ LL = -(TK/2) \log(2\pi) - (TK/2) -(T/2) \log|\hat\Sigma_{UU}| - (T/2) \sum_{i=1}^{r} \log (1-\hat\lambda_{i}) $$ Where \(\Sigma_{UU}\) is the variance matrix of residuals from the first auxiliary regression, i.e. regressing \(\Delta y_t\) on a constant and lags, \(\Delta y_{t-1}, \ldots, \Delta y_{t-p}\). \(\lambda_{i}\) are the eigenvalues from the \(\Sigma_{VV}^{-1}\Sigma_{VU}\Sigma_{UU}^{-1}\Sigma_{UV}\), see 20.2.9 in Hamilton (1994).

When the model is estimated with 2OLS, the LL is computed as: $$ LL = \log|\Sigma| $$

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.

References

Hamilton (1994) Time Series Analysis, Princeton University Press

Examples

Run this code
# NOT RUN {
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