Warning: This documentation is for scikits.learn version 0.7.1. — Latest stable version

Contents

6.10.3. scikits.learn.covariance.LedoitWolf

class scikits.learn.covariance.LedoitWolf(store_covariance=True)

LedoitWolf Estimator

Parameters :

store_covariance : bool

Specify if the estimated covariance is stored

Notes

The regularised covariance is:

(1 - shrinkage)*cov
        + shrinkage*mu*np.identity(n_features)

where mu = trace(cov) / n_features

Reference : “A Well-Conditioned Estimator for Large-Dimensional Covariance Matrices”, Ledoit and Wolf, Journal of Multivariate Analysis, Volume 88, Issue 2, February 2004, pages 365-411.

Attributes

covariance_ 2D ndarray, shape (n_features, n_features) Estimated covariance matrix (stored only is store_covariance is True)
precision_ 2D ndarray, shape (n_features, n_features) Estimated precision matrix
shrinkage_ float Scalar used to regularize the precision matrix estimation

Methods

fit(X)
log_likelihood(test_cov)
score(X_test)
__init__(store_covariance=True)