covEstimator {fPortfolio}R Documentation

Covariance Estimators

Description

Functions to estimate the sample mean and covariance of rectangular objects.

Usage

covEstimator(x, spec = NULL, ...)
mveEstimator(x, spec = NULL, ...)
mcdEstimator(x, spec = NULL, ...)

lpmEstimator(x, spec = NULL, ...)

kendallEstimator(x, spec = NULL, ...)
spearmanEstimator(x, spec = NULL, ...)

covMcdEstimator(x, spec = NULL, ...)
covOGKEstimator(x, spec = NULL, ...)
shrinkEstimator(x, spec = NULL, ...)
nnveEstimator(x, spec = NULL, ...)

Arguments

spec unused.
x any rectangular time series object which can be converted by the function as.matrix() into a matrix object, e.g. like an object of class timeSeries, data.frame, or mts.
... optional arguments to be passed to the underlying estimators.

Details

The functions are underlying the following algorithms:

covEstimator uses standard covariance estimation,
mveEstimator uses the function "cov.mve" from the MASS package,
mcdEstimator uses the function "cov.mcd" from the MASS package,
lpmEstimator returns lower partial moment estimator,
kendallEstimator returns Kendall's rank estimator,
spearmanEstimator returns Spearman's rankestimator,
covMcdEstimator requires "covMcd" from package robustbase,
covOGKEstimator requires "covOGK" from package robustbase,
nnveEstimator uses builtin from package covRobust,
shrinkEstimator uses builtin from package corpcor.

Value

the functions return a list with two entries named mu and Sigma. The first denotes the vector of column means, and the second the covariance matrix. Note, that the output of this function can be used as data input for the portfolio functions to compute the efficient frontier.

Author(s)

Juliane Schaefer and Korbinian Strimmer for R's corpcov package,
Diethelm Wuertz for the Rmetrics port.

References

Breiman L. (1996); Bagging Predictors, Machine Learning 24, 123–140.

Ledoit O., Wolf. M. (2003); ImprovedEestimation of the Covariance Matrix of Stock Returns with an Application to Portfolio Selection, Journal of Empirical Finance 10, 503–621.

Schaefer J., Strimmer K. (2005); A Shrinkage Approach to Large-Scale Covariance Estimation and Implications for Functional Genomics, Statist. Appl. Genet. Mol. Biol. 4, 32.

See Also

MultivariateDistribution.

Examples

## berndtInvest -
   LPP = as.timeSeries(data(LPP2005REC))[, 1:6]
   colnames(LPP)
   
## Classical Covariance Estimation:
   covEstimator(LPP)

[Package fPortfolio version 280.74 Index]