normal.test {energy} R Documentation

## Energy Test of Univariate Normality

### Description

Performs the energy test of univariate normality for the composite hypothesis Case 4, estimated parameters.

### Usage

normal.test(x, method=c("mc","limit"), R)
normal.e(x)


### Arguments

 x univariate data vector method method for p-value R number of replications if Monte Carlo method

### Details

If method="mc" this test function applies the parametric bootstrap method implemented in mvnorm.test.

If method="limit", the p-value of the test is computed from the asymptotic distribution of the test statistic under the null hypothesis. The asymptotic distribution is a quadratic form of centered Gaussian random variables, which has the form

\sum_{k=1}^\infty \lambda_k Z_k^2,

where \lambda_k are positive constants (eigenvalues) and Z_k are iid standard normal variables. Eigenvalues are pre-computed and stored internally. A p-value is computed using Imhof's method as implemented in the CompQuadForm package.

Note that the "limit" method is intended for moderately large samples because it applies the asymptotic distribution.

The energy test of normality was proposed and implemented by Szekely and Rizzo (2005). See mvnorm.test for more details.

### Value

normal.e returns the energy goodness-of-fit statistic for a univariate sample.

normal.test returns a list with class htest containing

 statistic observed value of the test statistic p.value p-value of the test estimate sample estimates: mean, sd data.name description of data

### Author(s)

Maria L. Rizzo mrizzo@bgsu.edu and Gabor J. Szekely

### References

Szekely, G. J. and Rizzo, M. L. (2005) A New Test for Multivariate Normality, Journal of Multivariate Analysis, 93/1, 58-80, doi: 10.1016/j.jmva.2003.12.002.

Mori, T. F., Szekely, G. J. and Rizzo, M. L. "On energy tests of normality." Journal of Statistical Planning and Inference 213 (2021): 1-15.

Rizzo, M. L. (2002). A New Rotation Invariant Goodness-of-Fit Test, Ph.D. dissertation, Bowling Green State University.

J. P. Imhof (1961). Computing the Distribution of Quadratic Forms in Normal Variables, Biometrika, Volume 48, Issue 3/4, 419-426.

mvnorm.test and mvnorm.e for the energy test of multivariate normality and the test statistic for multivariate samples.
  x <- iris[1:50, 1]