Fixing parameter description (for assume_centered)#13456
Fixing parameter description (for assume_centered)#13456agramfort merged 3 commits intoscikit-learn:masterfrom
Conversation
Fixing parameter description (for assume_centered)
|
They don't look like errors to me though. |
|
What if we used "will be" and "will not be" rather than "is" and "is not"
|
|
+1 |
|
👍 Updated according to your suggestion |
qinhanmin2014
left a comment
There was a problem hiding this comment.
please update empirical_covariance_.py accordingly
|
I've changed my mind here. I don't think "will be centered" and "will not be centered" is appropriate, because sometimes (e.g., ShrunkCovariance), we simply use a different method to estimate the covariance when the data is assumed to be centered. Maybe use something like "the input data is assumed to be centered"? |
jnothman
left a comment
There was a problem hiding this comment.
There are several other instances of the same parameter description, and we should change all together:
$ git grep -p -A2 assume_centered.:
sklearn/covariance/elliptic_envelope.py=class EllipticEnvelope(MinCovDet, OutlierMixin):
--
sklearn/covariance/elliptic_envelope.py: assume_centered : boolean, optional (default=False)
sklearn/covariance/elliptic_envelope.py- If True, the support of robust location and covariance estimates
sklearn/covariance/elliptic_envelope.py- is computed, and a covariance estimate is recomputed from it,
--
sklearn/covariance/empirical_covariance_.py=def empirical_covariance(X, assume_centered=False):
--
sklearn/covariance/empirical_covariance_.py: assume_centered : boolean
sklearn/covariance/empirical_covariance_.py- If True, data are not centered before computation.
sklearn/covariance/empirical_covariance_.py- Useful when working with data whose mean is almost, but not exactly
--
sklearn/covariance/empirical_covariance_.py=class EmpiricalCovariance(BaseEstimator):
--
sklearn/covariance/empirical_covariance_.py: assume_centered : bool
sklearn/covariance/empirical_covariance_.py- If True, data are not centered before computation.
sklearn/covariance/empirical_covariance_.py- Useful when working with data whose mean is almost, but not exactly
--
sklearn/covariance/graph_lasso_.py=class GraphicalLasso(EmpiricalCovariance):
--
sklearn/covariance/graph_lasso_.py: assume_centered : boolean, default False
sklearn/covariance/graph_lasso_.py- If True, data are not centered before computation.
sklearn/covariance/graph_lasso_.py- Useful when working with data whose mean is almost, but not exactly
--
sklearn/covariance/graph_lasso_.py=class GraphicalLassoCV(GraphicalLasso):
--
sklearn/covariance/graph_lasso_.py: assume_centered : boolean
sklearn/covariance/graph_lasso_.py- If True, data are not centered before computation.
sklearn/covariance/graph_lasso_.py- Useful when working with data whose mean is almost, but not exactly
--
sklearn/covariance/graph_lasso_.py=class GraphLasso(GraphicalLasso):
--
sklearn/covariance/graph_lasso_.py: assume_centered : boolean, default False
sklearn/covariance/graph_lasso_.py- If True, data are not centered before computation.
sklearn/covariance/graph_lasso_.py- Useful when working with data whose mean is almost, but not exactly
--
sklearn/covariance/graph_lasso_.py=class GraphLassoCV(GraphicalLassoCV):
--
sklearn/covariance/graph_lasso_.py: assume_centered : Boolean
sklearn/covariance/graph_lasso_.py- If True, data are not centered before computation.
sklearn/covariance/graph_lasso_.py- Useful when working with data whose mean is almost, but not exactly
--
sklearn/covariance/robust_covariance.py=class MinCovDet(EmpiricalCovariance):
--
sklearn/covariance/robust_covariance.py: assume_centered : bool
sklearn/covariance/robust_covariance.py- If True, the support of the robust location and the covariance
sklearn/covariance/robust_covariance.py- estimates is computed, and a covariance estimate is recomputed from
--
sklearn/covariance/shrunk_covariance_.py=class ShrunkCovariance(EmpiricalCovariance):
--
sklearn/covariance/shrunk_covariance_.py: assume_centered : boolean, default False
sklearn/covariance/shrunk_covariance_.py- If True, data are not centered before computation.
sklearn/covariance/shrunk_covariance_.py- Useful when working with data whose mean is almost, but not exactly
--
sklearn/covariance/shrunk_covariance_.py=def ledoit_wolf_shrinkage(X, assume_centered=False, block_size=1000):
--
sklearn/covariance/shrunk_covariance_.py: assume_centered : bool
sklearn/covariance/shrunk_covariance_.py- If True, data are not centered before computation.
sklearn/covariance/shrunk_covariance_.py- Useful to work with data whose mean is significantly equal to
--
sklearn/covariance/shrunk_covariance_.py=def ledoit_wolf(X, assume_centered=False, block_size=1000):
--
sklearn/covariance/shrunk_covariance_.py: assume_centered : boolean, default=False
sklearn/covariance/shrunk_covariance_.py- If True, data are not centered before computation.
sklearn/covariance/shrunk_covariance_.py- Useful to work with data whose mean is significantly equal to
--
sklearn/covariance/shrunk_covariance_.py=class LedoitWolf(EmpiricalCovariance):
--
sklearn/covariance/shrunk_covariance_.py: assume_centered : bool, default=False
sklearn/covariance/shrunk_covariance_.py- If True, data are not centered before computation.
sklearn/covariance/shrunk_covariance_.py- Useful when working with data whose mean is almost, but not exactly
--
sklearn/covariance/shrunk_covariance_.py=def oas(X, assume_centered=False):
--
sklearn/covariance/shrunk_covariance_.py: assume_centered : boolean
sklearn/covariance/shrunk_covariance_.py- If True, data are not centered before computation.
sklearn/covariance/shrunk_covariance_.py- Useful to work with data whose mean is significantly equal to
--
sklearn/covariance/shrunk_covariance_.py=class OAS(EmpiricalCovariance):
--
sklearn/covariance/shrunk_covariance_.py: assume_centered : bool, default=False
sklearn/covariance/shrunk_covariance_.py- If True, data are not centered before computation.
sklearn/covariance/shrunk_covariance_.py- Useful when working with data whose mean is almost, but not exactly|
I'd not yet seen your comments, @qinhanmin2014 , sorry for any duplication. |
|
If you let me know the comment text we want to go with, I'll make the changes in all files @jnothman pointed out above. I feel that something like |
|
I'm okay with that. I still think there is a little ambiguity but it
appears hard to avoid.
|
|
How about |
* Fixing parameter description (for assume_centered) Fixing parameter description (for assume_centered) * Update shrunk_covariance_.py * Update empirical_covariance_.py
* Fixing parameter description (for assume_centered) Fixing parameter description (for assume_centered) * Update shrunk_covariance_.py * Update empirical_covariance_.py
…arn#13456)" This reverts commit bbe482c.
…arn#13456)" This reverts commit bbe482c.
* Fixing parameter description (for assume_centered) Fixing parameter description (for assume_centered) * Update shrunk_covariance_.py * Update empirical_covariance_.py
Fixing parameter description (for the parameter assume_centered) and some minor grammatical errors.