VAR order in Cointegration Test

I am studying Johansen's Test using Tsay's book (Multivariate Time Series Analysis). The book has given some sample results of function ca.jo in r package urca, which is a typical way to do cointegration test in r:

m1 = VARorder(bnd) # summary table was suppressed.
selected order: aic =  11
selected order: bic =  3
selected order: hq =  3

m2 = ca.jo(bnd, K = 2, ecdet = c("none"))

######################
# Johansen-Procedure #
######################

Test type: maximal eigenvalue statistic (lambda max) , with linear trend

Eigenvalues (lambda):
[1] 0.054773196 0.004665298

Values of teststatistic and critical values of test:

test 10pct  5pct  1pct
r <= 1 |  2.84  6.50  8.18 11.65
r = 0  | 34.19 12.91 14.90 19.19

Eigenvectors, normalised to first column:
(These are the cointegration relations)

Aaa.l2    Baa.l2
Aaa.l2  1.0000000  1.000000
Baa.l2 -0.8856789 -2.723912

Weights W:

Aaa.l2      Baa.l2
Aaa.d -0.04696894 0.002477064
Baa.d  0.04046524 0.002139536


Tsay has mentioned that given the information criteria has picked order 3 as the optimal order, the example will be using $$VAR(3)$$ in the Johansen's Test; however as we can see in the command it was using order 2, i.e. $$K=2$$ in ca.jo function.

I don't think this is a typo. Does anyone know why it is of order 2 rather than order 3?

The Johansen test does not select the lag order. Instead, it must be specified. If left unspecified, the default lag order chosen is $$k=2$$.
• thanks; but I have chosen a lag as K=2, right? Since I gave K a value in the function call. Mar 15, 2019 at 1:29
• Yes, $k$ must be specified to use the function ca.jo. Are you sure Tsay wasn't referring to a different dataset when he stated the optimal lag length was 3? It could indeed be a typo.