Method used to compute the p-value. Can be "asymp",
"num" or "sim" as in LRExp.test.
nSamp
Number of samples used to compute the p-value when
method is "sim".
Details
The distribution of CV^2 is that of
Greenwood's statistic up to normalising constants. It
approximately normal with expectation 1 and standard deviation
2/sqrt(n) for a large sample size n. Yet the
convergence to the normal is known to be very slow.
Value
A list of test results.
statistic, p.value
The test statistic, i.e. the squared coefficient of
variation CV^2 and the p-value.
df
The sample size.
method
Description of the test method.
Note
This test is sometimes referred to as Wilk's exponentiality
test or as WE1 test. It works quite well for a Lomax
alternative (i.e. GPD with shape ξ >0), and hence can be
compared to Jackson's test and the Likelihood-Ratio (LR) test of
exponentiality. However, this test has lower power that of the two
others while having a comparable computation cost due to the
evaluation of the Greenwood's statistic distribution.
Author(s)
Yves Deville
References
S. Ascher (1990) "A Survey of Tests for Exponentiality"
Commun. Statist. Theory Methods, 19(5), pp. 1811-1525.
See Also
The function CV2 that computes the statistic and
LRExp.test or Jackson.test for functions
implementing comparable tests or exponentiality with the same
arguments.
Examples
n <- 30; nSamp <- 500
X <- matrix(rexp(n * nSamp), nrow = nSamp, ncol = n)
pVals <- apply(X, 1, function(x) CV2.test(x)$p.value)
plot(pVals) ## should be uniform on (0, 1)
Results
R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> library(Renext)
Loading required package: evd
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/Renext/CV2.test.Rd_%03d_medium.png", width=480, height=480)
> ### Name: CV2.test
> ### Title: CV2 test of exponentiality
> ### Aliases: CV2.test
>
> ### ** Examples
>
> n <- 30; nSamp <- 500
> X <- matrix(rexp(n * nSamp), nrow = nSamp, ncol = n)
> pVals <- apply(X, 1, function(x) CV2.test(x)$p.value)
> plot(pVals) ## should be uniform on (0, 1)
>
>
>
>
>
> dev.off()
null device
1
>