CUSUM-Test
Usage
raintest(formula, data=list())
Arguments
formula
|
a symbolic describtion for the model to be tested
|
data
|
an optional data frame containing the variables in the model.
By default the variables are taken from the environment which 'custest' is
called from
|
Description
custest
performs the CUSUM-Tests against structural change. This
test is based on recursive residuals and returns a random walk.Value
A vector containing the random-walk.Author(s)
Torsten Hothorn <hothorn@amadeus.statistik.uni-dortmund.de>References
Kraemer, W., Sonnberger, H. (1986): The linear regression model
under testSee Also
lm
Examples
# generate regressor
x <- c(1:30);
# generate a structural change
y <- c(1*x[1:10], 3*x[11:30]) + rnorm(30,0,1);
# perform CUSUM-Test
rw <- custest(y ~x -1);
# plot random walk
plot(rw);