CHPTest {MSTest} | R Documentation |
Carrasco, Hu, and Ploberger (2014) parameter stability test
Description
This function performs the CHP (2014) parameter stability test as outline in Carrasco, M., Hu, L. and Ploberger, W. (2014). Original source code can be found here.
Usage
CHPTest(Y, p, control = list())
Arguments
Y |
A ( |
p |
Integer determining the number of autoregressive lags. |
control |
List with test procedure options including:
|
Value
List of class CHPTest
(S3
object) with model attributes including:
mdl_h0: List with restricted model attributes. This will be of class
ARmdl
(S3
object). SeeARmdl
.supTS: supTS test statistic value.
expTS: expTS test statistic value.
supTS_N: A (
N x 1
) vector with simulated supTS test statistics under null hypothesis.expTS_N: A (
N x 1
) vector with simulated expTS test statistics under null hypothesis.pval_supTS: P-value for supTS version of parameter stability test.
pval_expTS: P-value for expTS version of parameter stability test.
supTS_cv: Vector with 90%, 95%, and 99% bootstrap critical values for supTS version of parameter stability test.
expTS_cv: Vector with 90%, 95%, and 99% bootstrap critical values for expTS version of parameter stability test.
control: List with test procedure options used.
References
Carrasco, Marine, Liang Hu, and Werner Ploberger. 2014. “Optimal test for Markov switching parameters.” Econometrica 82 (2): 765–784.
Examples
# load data used in Hamilton 1989
y84 <- as.matrix(hamilton84GNP$GNP_logdiff)
# Set test procedure options
control = list(N = 1000,
rho_b = 0.7,
msvar = FALSE)
# perform test with switch in mean only on Hamilton 1989 data
mdl_84_msmu <- CHPTest(y84, p = 4, control = control)
summary(mdl_84_msmu)