Learn R Programming

exptest (version 1.2)

hollander.exp.test: Hollander-Proshan test for exponentiality

Description

Performs Hollander-Proshan test for the composite hypothesis of exponentiality, see Hollander and Proshan (1972).

Usage

hollander.exp.test(x, simulate.p.value=FALSE, nrepl=2000)

Arguments

x
a numeric vector of data values.
simulate.p.value
a logical value indicating whether to compute p-values by Monte Carlo simulation.
nrepl
the number of replications in Monte Carlo simulation.

Value

  • A list with class "htest" containing the following components:
  • statisticthe value of the test statistic.
  • p.valuethe p-value for the test.
  • methodthe character string "Hollander-Proshan test for exponentiality".
  • data.namea character string giving the name(s) of the data.

Details

The test is based on the following statistic: $$J_n = \frac{1}{n(n - 1)(n - 2)}\, \sum_{i\ne j,k; j x_j+x_k}.$$ Under exponentiality, one has $$\sqrt{n}(J_n-\frac{1}{4})\stackrel{d}{\rightarrow}\mathcal N\left(0,frac{5}{432}\right).$$ (see Hollander and Proshan (1972)).

References

Hollander M., Proshan F. (1972): Testing whether new is better than used. --- Ann. Math. Stat., vol. 43, pp. 1136--1146.

Examples

Run this code
hollander.exp.test(rexp(25))
hollander.exp.test(rgamma(25,2))

Run the code above in your browser using DataLab