| runs.test(tseries) | R Documentation |
Computes the runs test statistic for the null of independence for
the series x.
This test searches for independence in the observed series by
examining the frequency of runs. Before computing the statistic,
zero values of x are eliminated.
Missing values are not allowed.
runs.test (x)
x |
a numeric vector or time series. |
"htest" containing the following components:
statistic |
the value of the test statistic. |
p.value |
the p-value of the test. |
method |
a character string indicating what type of test was performed. |
data.name |
a character string giving the name of the data. |
A. Trapletti
J. B. Cromwell, W. C. Labys and M. Terraza (1994): Univariate Tests for Time Series Models, Sage, Thousand Oaks, CA, pp. 28-30.
x <- rnorm (100) # no runs runs.test (x) x <- 1:100 # one big run runs.test (x)