Learn R Programming

MissMech (version 1.0.2)

Hawkins: Test Statistic for the Hawkins Homoscedasticity Test

Description

Produces the F_ij's and A_ij's that are used in the Hawkins' test of homogeneoity of covariances. See Hawkins (1981) and Jamshidian and Jalal (2010) for more details.

Usage

Hawkins(data, spatcnt)

Arguments

data
A matrix consisting of at least two columns and two rows.
spatcnt
The cumulative sum of the number of cases corresponding to each group.

Value

fij
A vector of F_ij statistics, see Hawkins (1981) reference.
a
A list containg A_ij statistics, see Hawkins (1981) reference.
ni
A vector consisting of the number of cases in each group.

References

Hawkins, D. M. (1981). ``A new test for multivariate normality and homoscedasticity,'' Technometrics, 23, 105-110.

Jamshidian, M. and Jalal, S. (2010). ``Tests of homoscedasticity, normality, and missing at random for incomplete multivariate data,'' Psychometrika, 75, 649-674.

Examples

Run this code
set.seed <- 50
n <- 200
p <- 4
pctmiss <- 0.2
y <- matrix(rnorm(n * p),nrow = n)
spatcnt <- c(20, 50, 70, 200)
h <- Hawkins(data=y, spatcnt)

Run the code above in your browser using DataLab