Title

segmcoint -- Tests for segmented cointegration
(cointegration holding only over part of the sample)

Syntax

segmcoint subcommand depvar indepvars [if] [in]
[, options]

where subcommand is one of:

kim Kim (2003) weighted-LS Phillips-Ouliaris and ADF tests, inf over segmentations

dm Davidson & Monticini (2010) subsample DF/PP tests, min over subsamples

mr Martins & Rodrigues (2021) residual sup-Wald tests, W(m) and Wmax

depvar and indepvars are the variables of the cointegrating regression;
the data must be tsset.

Description

segmcoint implements three complementary residual-based procedures that test
the null of no cointegration over the whole sample against the alternative
that a stable cointegrating relationship prevails over one or more subperiods,
while breaking down (nonstationary error) over others. This situation
- segmented cointegration - was introduced by
Kim (2003) and explains why standard full-sample
Engle-Granger / Phillips-Ouliaris tests often fail to confirm a well understood
long-run relationship: a relatively short interval of nonstationary deviation
can dominate the full-sample statistic and mask the relationship.

The three subcommands span the literature:

o kim estimates the cointegrating vector by weighted least squares on a
trial cointegration set, forms Phillips-Perron-Ouliaris (Zrho, Zt)
or ADF statistics, and takes the infimum over all admissible segmentations.
It also dates the noncointegration interval.

o dm computes an ordinary DF or PP cointegration statistic on subsamples
of the data (split-sample, incremental, or rolling) and takes the minimum.
No model is estimated under the alternative and the break type/number need not
be specified.

o mr runs a residual-based sup-Wald persistence-change test that allows
multiple regimes switching between cointegration and no cointegration, dates the
breaks by global SSR minimisation, and reports the double-maximum statistic Wmax.

See help segmcoint methods for the equation-by-equation
derivation and the step->equation compatibility map.

Subcommands

Each subcommand has its own help page with full syntax, options and stored results:

segmcoint kim - Kim (2003)

segmcoint dm - Davidson & Monticini (2010)

segmcoint mr - Martins & Rodrigues (2021)

Common options

deterministic(string) deterministic terms: none, const
(default), or trend (intercept + linear trend); these correspond to Kim's
Case I / II / III and to the Martins-Rodrigues cases (a)/(b)/(c)

graph produce a diagnostic plot of each statistic against its 5%
critical value

graphname(name) name for the saved graph

noheader suppress the header block

All statistics test H0: no cointegration over the whole sample. For kim and
dm the statistics are in the lower tail (reject when the statistic is
below the critical value); for mr the Wald statistics are in the upper
tail (reject when above).

Examples

Setup

. webuse or use your own tsset time series

. tsset time

Kim (2003), intercept, date the noncointegration interval, plot

. segmcoint kim y x1 x2, deterministic(const) graph

Davidson-Monticini rolling test with window length 0.35T

. segmcoint dm y x, deterministic(const) lambda0(0.35) statistic(pp)

Martins-Rodrigues sup-Wald with up to 4 breaks, intercept + trend

. segmcoint mr y x1 x2, deterministic(trend) maxbreaks(4)

A complete, self-checking demonstration ships with the package:

. do segmcoint_example.do

Stored results

Each subcommand is rclass and returns its statistics, critical-value
matrices and p-value information in r(); see the individual help pages.

References

Davidson, J., and A. Monticini. 2010. Tests for cointegration with structural
breaks based on subsamples. Computational Statistics & Data Analysis 54:
2498-2511.

Kim, J.-Y. 2003. Inference on segmented cointegration.
Econometric Theory 19: 620-639.

Martins, L. F., and P. M. M. Rodrigues. 2021. Tests for segmented cointegration:
an application to US governments' budgets. Empirical Economics 63: 567-600.

Author

Dr Merwan Roudane

merwanroudane920@gmail.com

github.com/merwanroudane