Learn R Programming

exptest (version 1.2)

atkinson.exp.test: Atkinson test for exponentiality

Description

Performs Atkinson test for the composite hypothesis of exponentiality, see e.g. Mimoto and Zitikis (2008).

Usage

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

Arguments

x
a numeric vector of data values.
p
a parameter of the test (see below).
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 Atkinson statistic.
  • p.valuethe p-value for the test.
  • methodthe character string "Atkinson test for exponentiality".
  • data.namea character string giving the name(s) of the data.

Details

The Atkinson test for exponentiality is based on the following statistic: $$T_n(p) = \sqrt{n}\left| \frac{\left(n^{-1}\sum_{i=1}^n{X_i^p}\right)^{1/p}}{\overline{X}} -(\Gamma(1+p))^{\frac{1}{p}}\right|.$$ The statistic is asymptotically normal: $T_n(p) \to \left| N(0,\sigma^2(p))\right|$, where $$\sigma^2(p) = \left(\Gamma(1+p)\right)^{\frac{2}{p}}\left( -1 - \frac{1}{p^2} + \frac{\Gamma(1+2p)}{p^2\Gamma^2(1+p)}\right).$$

References

Mimoto, N. and Zitikis, R. (2008): The Atkinson index, the Moran statistic, and testing exponentiality. --- J. Japan Statist. Soc., vol. 38, pp. 187--205.

Examples

Run this code
atkinson.exp.test(rexp(100))
atkinson.exp.test(rchisq(100,3))

Run the code above in your browser using DataLab