# jcontest

Johansen constraint test

## Syntax

## Description

returns the rejection decisions `h`

= jcontest(`Y`

,`r`

,`test`

,`Cons`

)`h`

from conducting the Johansen
constraint test, which assesses linear constraints on either the error-correction
(adjustment) speeds *A* or the cointegration space spanned by the
cointegrating matrix *B* in the reduced-rank VEC(*q*) model of the multivariate time series
*y _{t}*, where:

`Y`

is a matrix of observations of*y*._{t}`r`

is the common rank of matrices*A*and*B*.`test`

specifies the constraint types, including linear or equality constraints on*A*or*B*.`Cons`

specifies the test constraint values.

For a particular test, the constraint type and values form the null
hypotheses tested against the alternative hypothesis *H*(*r*) of cointegration rank less than or equal to *r* (an
unconstrained VEC model). The tests also produce maximum likelihood estimates of the
parameters in the VEC(*q*) model, subject to the constraints.

Each element of `test`

and `Cons`

results in a
separate test.

returns the table `StatTbl`

= jcontest(`Tbl`

,`r`

,`test`

,`Cons`

)`StatTbl`

containing variables for the test results,
statistics, and settings from conducting the Johansen constraint test on all variables of
the input table or timetable `Tbl`

.

To select a subset of variables in `Tbl`

to test, use the
`DataVariables`

name-value argument.

`[___] = jcontest(___,`

specifies options using one or more name-value arguments in
addition to any of the input argument combinations in previous syntaxes.
`Name=Value`

)`jcontest`

returns the output argument combination for the
corresponding input arguments.

In addition to `bp`

, some options control the number of tests to
conduct.

For example, `jcontest(Tbl,r,test,Cons,Model="H2",DataVariables=1:5)`

tests the first 5 variables in the input table `Tbl`

using the Johansen
model that excludes all deterministic terms.

## Examples

## Input Arguments

## Output Arguments

## More About

## Tips

`jcontest`

compares finite-sample statistics to asymptotic critical values, and tests can show significant size distortions for small samples [2]. Larger samples lead to more reliable inferences.To convert VEC(

*q*) model parameters in the`mles`

output to vector autoregressive (VAR) model parameters, use the`vec2var`

function.

## Algorithms

`jcontest`

identifies deterministic terms that are outside of the cointegrating relations,*c*_{1}and*d*_{1}, by projecting constant and linear regression coefficients, respectively, onto the orthogonal complement of*A*.The parameters

*A*and*B*in the reduced-rank VEC(*q*) model are not identifiable.`jcontest`

identifies*B*using the methods in [3], depending on the test.Tests on

*B*answer questions about the space of cointegrating relations. Tests on*A*answer questions about common driving forces in the system. For example, an all-zero row in*A*indicates a variable that is weakly exogenous with respect to the coefficients in*B*. Such a variable can affect other variables, but it does not adjust to disequilibrium in the cointegrating relations. Similarly, a standard unit vector column in*A*indicates a variable that is exclusively adjusting to disequilibrium in a particular cointegrating relation.Constraint matrices

`R`

satisfying*R*′*A*= 0 or*R*′*B*= 0 are equivalent to*A*=*H**φ*or*B*=*H**φ*, where*H*is the orthogonal complement of*R*(`null(R')`

) and*φ*is a vector of free parameters.

## References

[1] Hamilton, James D. *Time Series Analysis*. Princeton, NJ: Princeton University Press, 1994.

[2] Haug, A. “Testing Linear Restrictions
on Cointegrating Vectors: Sizes and Powers of Wald Tests in Finite
Samples.” *Econometric Theory*. v. 18,
2002, pp. 505–524.

[3] Johansen, S. *Likelihood-Based Inference in Cointegrated Vector Autoregressive Models*. Oxford: Oxford University Press, 1995.

[4] Juselius, K. *The Cointegrated VAR Model*. Oxford: Oxford University Press, 2006.

[5] Morin, N. "Likelihood Ratio Tests on Cointegrating Vectors,
Disequilibrium Adjustment Vectors, and their Orthogonal Complements." *European
Journal of Pure and Applied Mathematics*. v. 3, 2010, pp. 541–571.

## Version History

**Introduced in R2011a**