Description Usage Arguments Details Value Author(s) References Examples

View source: R/gini.exp.test.R

Performs test for the composite hypothesis of exponentiality based on the Gini statistic, see e.g. Gail and Gastwirth (1978).

1 | ```
gini.exp.test(x, simulate.p.value=FALSE, nrepl=2000)
``` |

`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. |

The test is based on the Gini statistic

*
G_n = \frac{∑_{i,j=1}^n |X_i-X_j|}{2n(n-1)\overline{X}}.
*

Under exponentiality, the normalized statistic *(12(n-1))^{1/2}(G_n-0.5)* is asymptotically standard normal (see, e.g., Gail and Gastwirth (1978)).

A list with class "htest" containing the following components:

`statistic` |
the value of the Gini statistic. |

`p.value ` |
the p-value for the test. |

`method` |
the character string "Test for exponentiality based on the Gini statistic". |

`data.name` |
a character string giving the name(s) of the data. |

Alexey Novikov, Ruslan Pusev and Maxim Yakovlev

Gail, M.H. and Gastwirth, J.L. (1978): A scale-free goodness-of-fit test for the exponential distribution based on the Gini statistic. — J. R. Stat. Soc. Ser. B, vol. 40, No. 3, pp. 350–357.

1 2 | ```
gini.exp.test(rexp(100))
gini.exp.test(runif(100, min = 0, max = 1))
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.