| Type: | Package | 
| Title: | Stein's Covariance Estimator | 
| Version: | 0.1.0 | 
| Date: | 2016-04-12 | 
| Author: | Brett Naul <brettnaul@gmail.com> | 
| Maintainer: | Brett Naul <brettnaul@gmail.com> | 
| Description: | Estimates a covariance matrix using Stein's isotonized covariance estimator, or a related estimator suggested by Haff. | 
| License: | GPL-2 | GPL-3 [expanded from: GPL (≥ 2)] | 
| Suggests: | testthat | 
| RoxygenNote: | 5.0.1 | 
| NeedsCompilation: | no | 
| Packaged: | 2016-04-13 16:07:47 UTC; brettnaul | 
| Repository: | CRAN | 
| Date/Publication: | 2016-04-13 21:35:23 | 
Stein/Haff's covariance estimator
Description
Stein/Haff's covariance estimator
Usage
haff_cov(S, n)
Arguments
| S | Sample covariance matrix | 
| n | Number of observations | 
Value
Estimated covariance matrix
References
Haff, L. R. "The Variational Form of Certain Bayes Estimators." The Annals of Statistics 19, no. 3 (1991): 1163-1190.
Lin, S.P. and Perlman, M.D.. "A Monte Carlo comparison of four estimators of a covariance matrix." Multivariate Analysis 6 (1985): 411-429.
Stein, C. "Estimation of a covariance matrix". Rietz Lecture (1975).
Examples
p <- 5
n <- 10
S <- rWishart(1, n, diag(p))[,,1]
haff_cov(S, n)
Stein/Haff's ordered eigenvalue estimates
Description
Stein/Haff's ordered eigenvalue estimates
Usage
haff_eig(l, n)
Arguments
| l | Sample eigenvalues | 
| n | Number of observations | 
Value
Estimated eigenvalues
Examples
p <- 5
n <- 10
S <- rWishart(1, n, diag(p))[,,1]
l <- eigen(S)$val
haff_eig(l, n)
Stein's isotonized covariance estimator
Description
Stein's isotonized covariance estimator
Usage
iso_cov(S, n)
Arguments
| S | Sample covariance matrix | 
| n | Number of observations | 
Value
Estimated covariance matrix
Examples
p <- 5
n <- 10
S <- rWishart(1, n, diag(p))[,,1]
iso_cov(S, n)
Stein's isotonized eigenvalue estimates
Description
Stein's isotonized eigenvalue estimates
Usage
iso_eig(l, n)
Arguments
| l | Sample eigenvalues | 
| n | Number of observations | 
Value
Estimated eigenvalues
Examples
p <- 5
n <- 10
S <- rWishart(1, n, diag(p))[,,1]
l <- eigen(S)$val
iso_eig(l, n)
Stein's raw (unisotonized) eigenvalue estimates
Description
Stein's raw (unisotonized) eigenvalue estimates
Usage
stein_eig(l, n)
Arguments
| l | Sample eigenvalues | 
| n | Number of observations | 
Value
Estimated eigenvalues
Examples
p <- 5
n <- 10
S <- rWishart(1, n, diag(p))[,,1]
l <- eigen(S)$val
stein_eig(l, n)