CS {mnt}R Documentation

Statistic of the test of Cox and Small

Description

This function returns the (approximated) value of the test statistic of the test of Cox and Small (1978).

Usage

CS(data, Points = NULL)

Arguments

data

a n x d matrix of d dimensional data vectors.

Points

points for approximation of the maximum on the sphere. Points=NULL generates 5000 uniformly distributed Points on the d dimensional unit sphere.

Details

The test statistic is Tn,CS=maxb{xRd:x=1}ηn2(b)T_{n,CS}=\max_{b\in\{x\in\mathbf{R}^d:\|x\|=1\}}\eta_n^2(b), where

ηn2(b)=n1j=1nYn,j(bYn,j)22(n1j=1n(bYn,j)3)2n1j=1n(bYn,j)41(n1j=1n(bYn,j)3)2\eta_n^2(b)=\frac{\left\|n^{-1}\sum_{j=1}^nY_{n,j}(b^\top Y_{n,j})^2\right\|^2-\left(n^{-1}\sum_{j=1}^n(b^\top Y_{n,j})^3\right)^2}{n^{-1}\sum_{j=1}^n(b^\top Y_{n,j})^4-1-\left(n^{-1}\sum_{j=1}^n(b^\top Y_{n,j})^3\right)^2}

. Here, Yn,j=Sn1/2(XjXn)Y_{n,j}=S_n^{-1/2}(X_j-\overline{X}_n), j=1,,nj=1,\ldots,n, are the scaled residuals, Xn\overline{X}_n is the sample mean and SnS_n is the sample covariance matrix of the random vectors X1,,XnX_1,\ldots,X_n. To ensure that the computation works properly nd+1n \ge d+1 is needed. If that is not the case the function returns an error. Note that the maximum functional has to be approximated by a discrete version, for details see Ebner (2012).

Value

approximation of the value of the test statistic of the test of Cox and Small (1978).

References

Cox, D.R. and Small, N.J.H. (1978), Testing multivariate normality, Biometrika, 65:263–272.

Ebner, B. (2012), Asymptotic theory for the test for multivariate normality by Cox and Small, Journal of Multivariate Analysis, 111:368–379.

Examples

CS(MASS::mvrnorm(50,c(0,1),diag(1,2)))


[Package mnt version 1.3 Index]