DLMMCtest: Maximized Monte-Carlo Moment-based test for MS AR model

Description Usage Arguments Value References

View source: R/moment_test.R

Description

This function performs the MMC version of the Moment-Based test for MS AR models presented in Dufour & Luger (2017). It is useful when nuissance parameters are present in the null disribution.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
DLMMCtest(
  Y,
  p = NULL,
  x = NULL,
  N = 100,
  N2 = 10000,
  N3 = 1e+05,
  searchType = "randSearch_paramCI",
  optimOptions = NULL
)

Arguments

Y

Series to be tested

p

Order of autoregressive components AR(p).

x

exogenous variables if any. Test in Dufour & Luger is model for AR lags

N

number of samples

N2

number of simulations when approximating distribution used to combine p-values (eq. 16).

N3

number of parameter values to try for nuissance params. Used only when calling gridSearch_paramCI or randSearch_paramCI.

searchType

Type of optimization algorithm when searching nuissance parameter space. Avaiable options are: GenSA, GA, PSO, randSearch_paramCI and gridSearch_paramCI. Default is set to randSearch_paramCI to match results in paper.

Value

List with model and test results.

References

Dufour, J. M., & Luger, R. (2017). Identification-robust moment-based tests for Markov switching in autoregressive models. Econometric Reviews, 36(6-9), 713-727.


roga11/MSTest_v1 documentation built on Dec. 22, 2021, 5:16 p.m.