kpss_2br: KPSS Unit Root Test with Two Structural Breaks

kpss_2brR Documentation

KPSS Unit Root Test with Two Structural Breaks

Description

Implement the kpss unit root test with two unknown structural breaks. Carrion-i-Silvestre and Sanso (2007) extends Kurozumi (2002) to two breaks, and create critical values.

Usage

kpss_2br(y, lags = c("short", "long", "nil"), model=1, use=c("nw","ba"),trace=TRUE)

Arguments

y

Vector to be tested for a unit root.

lags

Lags used for correction of error term.

model

Modelling where the unknown structural change occurs.
1 = AAn (Level shift without trend);
2 = AA (Level shift with trend);
3 = BB (Trend shift);
4 = CC (Level and trend shift)
Default is 1.

use

User specified lags for correction of error term. The default is the lag determined by Newey-West bandwidth "nw" with Bartlett "ba" kernel. Users can input your own number. This version suports two bandwidth functions: "nw" for Newey-West, "and" for Andrews. Three kernel functions are supported by both bandwidth functions: "ba"=Bartlett, "pa"=Parzen, "qs"=Qudratic Spectral

trace

Logical. If TURE (default), then screen displays the sequential progress.

Details

lags="short" sets the number of lags to \sqrt[4]{4 \times (n/100)}, whereas lags="long" sets the number of lags to \sqrt[4]{12 \times (n/100)}. If lags="nil" is choosen, then no error correction is made. Furthermore, lags and use are mutually exclusive. As long as use is not set to be NULL, its argumenta will be chosen fisrt. One can specify a different number of maximum lags by setting use accordingly.

Value

teststat

The test statistic.

cval

The critical values that are tabulated in Carrion-i-Silvestre and Sanso, A. (2007).

bpoint1

The first breaking point that corresponds to the teststat.

bpoint2

The second breaking point that corresponds to the teststat.

timeElapse

Time elapsed for sequential search.

Author(s)

Ho Tsung-wu <tsungwu@ntnu.edu.tw>, College of Management, National Taiwan Normal University.

References

Carrion-i-Silvestre, J. L. and Sanso, A. (2006) A guide to the computation of stationarity tests. Empirical Economics, 31(2), 433-448.
Carrion-i-Silvestre, J. L. and Sanso, A. (2007) The KPSS test with two structural breaks,Spanish Economic Review, 9(2), 105-127.
Kwiatkowski, D., Phillips, P.C.B., Schmidt, P. and Shin, Y. (1992) Testing the Null Hypothesis of Stationarity Against the Alternative of a Unit Root: How Sure Are We That Economic Time Series Have a Unit Root? Journal of Econometrics, 54, 159-178.
Kurozumi, E. (2002) Testing for stationarity with a break. Journal of Econometrics,108(1), 105-127.

Examples


data(macro)


y=macro[1:200,"INF"]

KPSS2=kpss_2br(y,model=1,use=c("nw","ba"))
KPSS2$teststat
KPSS2$cval
y[KPSS2$bpoint,]




COINT documentation built on Sept. 9, 2025, 5:51 p.m.

Related to kpss_2br in COINT...