raintest(formula, fraction = 0.5, order.by = NULL, center = NULL,
data=list())
fraction*n
if n
is the number of observations
in the model.~ x
. The observations in the model
are ordered by the size of x
. If set to NULL
(the
default) the observations are assumed tcenter
is smaller than 1 it is
interpreted as percentages of data, i.e. the subset is chosen that
n*fraction
observations are around observation number
n*center
. If center
is graintest
is called from."htest"
containing the following components:parameter
degrees of freedom.Examples can not only be found on this page, but also on the help pages of the
data sets bondyield
, currencysubstitution
,
growthofmoney
, moneydemand
,
unemployment
,
wages
.
W. Kr�mer & H. Sonnberger (1986), The Linear Regression Model under Test. Heidelberg: Physica
lm
x <- c(1:30)
y <- x^2 + rnorm(30,0,2)
rain <- raintest(y ~ x)
rain
## critical value
qf(0.95, rain$parameter[1], rain$parameter[2])
Run the code above in your browser using DataLab