sphericitytests: Sphericity tests

Sphericity testsR Documentation

Sphericity tests

Description

Tests of sphericity based on spatial signs and spatial signs of pairwise differences.

Usage

 sr.sphere.test(X, score = c("sign", "symmsign"), shape = NULL,
na.action = na.fail) 

Arguments

X

a matrix or a data frame

score

a character string indicating which transformation of the observations should be used

shape

a matrix with which the data should be standardized before the sphericity test

na.action

a function which indicates what should happen when the data contain 'NA's. Default is to fail.

Details

The test is for a null hypothesis of the form “true shape matrix is equal to the identity matrix”. Effectively, giving a matrix as shape will produce a test of whether the true shape is equal (in fact, proportional, since the scale of shape will have no effect) to it. In that case the test will still be for sphericity but the data is standardized beforehand.

Value

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

statistic

the value of the statistic

parameter

the degrees of freedom for the statistic

p.value

the p-value for the test

null.value

the specified hypothesized value of the shape (always diag(p) where p is the number of dimensions)

alternative

a character string with the value 'two.sided'.

method

a character string indicating what type of test was performed

data.name

a character string giving the name of the data

Author(s)

Seija Sirkia, seija.sirkia@iki.fi

References

Sirkia et al. (2009) Tests and estimates of shape based on spatial signs and ranks. Journal of Nonparametric Statistics, 21, 155-176.

See Also

sign and rank covariance matrices

Examples

A<-matrix(c(1,2,-3,4,3,-2,-1,0,4),ncol=3)
X<-matrix(rnorm(600),ncol=3)%*%t(A)
sr.sphere.test(X,score="sign")

SpatialNP documentation built on March 18, 2022, 8:02 p.m.