Title: | Covariance Matrix Tests |
---|---|
Description: | Testing functions for Covariance Matrices. These tests include high-dimension homogeneity of covariance matrix testing described by Schott (2007) <doi:10.1016/j.csda.2007.03.004> and high-dimensional one-sample tests of covariance matrix structure described by Fisher, et al. (2010) <doi:10.1016/j.jmva.2010.07.004>. Covariance matrix tests use C++ to speed performance and allow larger data sets. |
Authors: | Ben Barnard [aut, cre], Dean Young [aut] |
Maintainer: | Ben Barnard <[email protected]> |
License: | GPL-2 |
Version: | 0.1.4 |
Built: | 2024-11-23 04:16:51 UTC |
Source: | https://github.com/benbarnard/covtestr |
Testing functions for Covariance Matrices. These tests include high-dimension homogeneity of covariance matrix testing described by Schott (2007) 10.1016/j.csda.2007.03.004 and high-dimensional one-sample tests of covariance matrix structure described by Fisher, et al. (2010) 10.1016/j.jmva.2010.07.004. Covariance matrix tests use C++ to speed performance and allow larger data sets.
Performs Tests for the structure of covariance matrices.
Ahmad2015(x, Sigma = "identity", ...) Chen2010(x, Sigma = "identity", ...) Fisher2012(x, Sigma = "identity", ...) LedoitWolf2002(x, Sigma = "identity", ...) Nagao1973(x, Sigma = "identity", ...) Srivastava2005(x, Sigma = "identity", ...) Srivastava2011(x, Sigma = "identity", ...)
Ahmad2015(x, Sigma = "identity", ...) Chen2010(x, Sigma = "identity", ...) Fisher2012(x, Sigma = "identity", ...) LedoitWolf2002(x, Sigma = "identity", ...) Nagao1973(x, Sigma = "identity", ...) Srivastava2005(x, Sigma = "identity", ...) Srivastava2011(x, Sigma = "identity", ...)
x |
data as a list of matrices |
Sigma |
Population covariance matrix as a matrix |
... |
other options passed to covTest method |
A list with class "htest" containing the following components:
statistic |
the value of equality of covariance test statistic |
parameter |
the degrees of freedom for the chi-squared statistic |
p.value |
the p=value for the test |
estimate |
the estimated covariances if less than 5 dimensions |
null.value |
the specified hypothesized value of the covariance difference |
alternative |
a character string describing the alternative hyposthesis |
method |
a character string indicating what type of equality of covariance test was performed |
data.name |
a character string giving the names of the data |
Ahmad, M. R. and Rosen, D. von. (2015). Tests for High-Dimensional Covariance Matrices Using the Theory of U-statistics. Journal of Statistical Computation and Simulation, 85(13), 2619-2631. 10.1080/00949655.2014.948441
Chen, S., et al. (2010). Tests for High-Dimensional Covariance Matrices. Journal of the American Statistical Association, 105(490):810-819. 10.1198/jasa.2010.tm09560
Fisher, T. J. (2012). On Testing for an Identity Covariance Matrix when the Dimensionality Equals or Exceeds the Sample Size. Journal of Statistical Planning and Infernece, 142(1), 312-326. 10.1016/j.jspi.2011.07.019
Ledoit, O., and Wolf, M. (2002). Some Hypothesis Tests for the Covariance Matrix When the Dimension Is Large Compared to the Sample Size. The Annals of Statistics, 30(4), 1081-1102. 10.1214/aos/1031689018
Nagao, H. (1973). On Some Test Criteria for Covariance Matrix. The Annals of Statistics, 1(4), 700-709
Srivastava, M. S. (2005). Some Tests Concerning the Covariance Matrix in High Dimensional Data. Journal of the Japan Statistical Society, 35(2), 251-272. 10.14490/jjss.35.251
Srivastava, M. S., Kollo, T., and Rosen, D. von. (2011). Some Tests for the Covariance Matrix with Fewer Observations then the Dimension Under Non-normality. Journal of Multivariate Analysis, 102(6), 1090-1103. 10.1016/j.jmva.2011.03.003
Other Testing for Structure of Covariance Matrices: structureCovariances
Chen2010(as.matrix(iris[1:50, 1:3]))
Chen2010(as.matrix(iris[1:50, 1:3]))
Performs tests for homogeneity of 2 and k covariance matrices.
Ahmad2017(x, ...) BoxesM(x, ...) Chaipitak2013(x, ...) Ishii2016(x, ...) Schott2001(x, ...) Schott2007(x, ...) Srivastava2007(x, ...) Srivastava2014(x, ...) SrivastavaYanagihara2010(x, ...)
Ahmad2017(x, ...) BoxesM(x, ...) Chaipitak2013(x, ...) Ishii2016(x, ...) Schott2001(x, ...) Schott2007(x, ...) Srivastava2007(x, ...) Srivastava2014(x, ...) SrivastavaYanagihara2010(x, ...)
x |
data as a list of matrices |
... |
other options passed to covTest method |
A list with class "htest" containing the following components:
statistic |
the value of homogeneity of covariance test statistic |
parameter |
the degrees of freedom for the chi-squared statistic |
p.value |
the p=value for the test |
estimate |
the estimated covariances if less than 5 dimensions |
null.value |
the specified hypothesized value of the covariance difference |
alternative |
a character string describing the alternative hyposthesis |
method |
a character string indicating what type of homogeneity of covariance test was performed |
data.name |
a character string giving the names of the data |
Ahmad, R. (2017). Location-invariant test of homogeneity of large-dimensional covariance matrices. Journal of Statistical Theory and Practice, 11(4):731-745. 10.1080/15598608.2017.1308895
Chaipitak, S. and Chongcharoen, S. (2013). A test for testing the equality of two covariance matrices for high-dimensional data. Journal of Applied Sciences, 13(2):270-277. 10.3923/jas.2013.270.277
Ishii, A., Yata, K., and Aoshima, M. (2016). Asymptotic properties of the first pricipal component and equality tests of covariance matrices in high-dimesion, low-sample-size context. Journal of Statistical Planning and Inference, 170:186-199. 10.1016/j.jspi.2015.10.007
Schott, J (2001). Some Tests for the Equality of Covariance Matrices. Journal of Statistical Planniing and Inference. 94(1), 25-36. 10.1016/S0378-3758(00)00209-3
Schott, J. (2007). A test for the equality of covariance matrices when the dimension is large relative to the sample sizes. Computational Statistics & Data Analysis, 51(12):6535-6542. 10.1016/j.csda.2007.03.004
Srivastava, M. S. (2007). Testing the equality of two covariance matrices and independence of two sub-vectors with fewer observations than the dimension. InInternational Conference on Advances in InterdisciplinaryStistics and Combinatorics, University of North Carolina at Greensboro, NC, USA.
Srivastava, M., Yanagihara, H., and Kubokawa T. (2014). Tests for covariance matrices in high dimension with less sample size. Journal of Multivariate Analysis, 130:289-309. 10.1016/j.jmva.2014.06.003
Srivastava, M. and Yanagihara, H. (2010). Testing the equality of several covariance matrices with fewer observation that the dimension. Journal of Multivariate Analysis, 101(6):1319-1329. 10.1016/j.jmva.2009.12.010
Other Testing for Homogeneity of Covariance Matrices: homogeneityCovariances
irisSpecies <- unique(iris$Species) iris_ls <- lapply(irisSpecies, function(x){as.matrix(iris[iris$Species == x, 1:4])} ) names(iris_ls) <- irisSpecies Ahmad2017(iris_ls)
irisSpecies <- unique(iris$Species) iris_ls <- lapply(irisSpecies, function(x){as.matrix(iris[iris$Species == x, 1:4])} ) names(iris_ls) <- irisSpecies Ahmad2017(iris_ls)
Performs 2 and k sample homogeneity of covariance matrices test using test, 'covTest.'
homogeneityCovariances(x, ..., covTest = BoxesM)
homogeneityCovariances(x, ..., covTest = BoxesM)
x |
data as a data frame, list of matrices, grouped data frame, or resample object |
... |
other options passed to covTest method |
covTest |
homogeneity of covariance matrices test method |
The homogeneityCovariances
function is a wrapper function that formats the data
for the specific covTest
functions.
A list with class "htest" containing the following components:
statistic |
the value of homogeneity of covariance test statistic |
parameter |
the degrees of freedom for the chi-squared statistic |
p.value |
the p=value for the test |
estimate |
the estimated covariances if less than 5 dimensions |
null.value |
the specified hypothesized value of the covariance difference |
alternative |
a character string describing the alternative hyposthesis |
method |
a character string indicating what type of homogeneity of covariance test was performed |
data.name |
a character string giving the names of the data |
Other Testing for Homogeneity of Covariance Matrices: Ahmad2017
homogeneityCovariances(iris, group = Species)
homogeneityCovariances(iris, group = Species)
Performs a structure of a covariance matrix test.
structureCovariances(x, Sigma = "identity", ..., covTest = Nagao1973)
structureCovariances(x, Sigma = "identity", ..., covTest = Nagao1973)
x |
data |
Sigma |
Population covariance matrix |
... |
other options passed to covTest method |
covTest |
structure of covariance matrix test method |
The structureCovariances
function is a wrapper function that formats the data
for the specific covTest
functions.
A list with class "htest" containing the following components:
statistic |
the value of equality of covariance test statistic |
parameter |
the degrees of freedom for the chi-squared statistic |
p.value |
the p=value for the test |
estimate |
the estimated covariances if less than 5 dimensions |
null.value |
the specified hypothesized value of the covariance difference |
alternative |
a character string describing the alternative hyposthesis |
method |
a character string indicating what type of equality of covariance test was performed |
data.name |
a character string giving the names of the data |
Other Testing for Structure of Covariance Matrices: Ahmad2015