-
-
Notifications
You must be signed in to change notification settings - Fork 25.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DOC add link to plot_covariance_estimation example in docstrings and userguide #30429
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @stefanogaspari,
thanks for your PR. I have added a few remarks.
In general, I think the example should only be mentioned in the docstrings of OAS
and LedoitWolf
, as their regularization is the topic of the example; and GridSearchCV
is only used the measure their performance.
Hi @StefanieSenger , |
31a1a38
to
3959382
Compare
References scikit-learn#26927 What does this fix? Added links to plot_covariance_estimation example in docstrings and userguide
… in docstrings and userguide
3959382
to
e4a7eb2
Compare
Thank you, @stefanogaspari, that looks very good. Please go ahead removing the mention of the example in the |
Hi @StefanieSenger , good afternoon |
Oh yes, now I see. And you also need to fix the doctest issues shown in the CI. |
:class:`OAS` objects to data and for visualizing their performances in terms of | ||
likelihood. | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove the blank line.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@StefanieSenger : maybe I shall add .. rubric:: Examples
before the note added at the end of the top paragraph "2.6 Covariance estimation"
.. rubric:: Examples
* See :ref:
sphx_glr_auto_examples_covariance_plot_covariance_estimation.py for an example on how to fit :class:
ShrunkCovariance , :class:
LedoitWolf and :class:
OAS objects to data and for visualizing their performances in terms of likelihood.
I will try it. What do you think about it?
doc/modules/covariance.rst
Outdated
.. rubric:: Examples | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.. rubric:: Examples |
Remove section title including blank line that follows.
The same applies below.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll do it right away. This is good to know for future PRs as well. Thanks
* See also :ref:`sphx_glr_auto_examples_covariance_plot_covariance_estimation.py` | ||
for an example on how to fit a :class:`LedoitWolf` object to data and | ||
for visualizing the performances of the Ledoit-Wolf estimator in | ||
terms of likelihood. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
terms of likelihood. | |
terms of likelihood. | |
And it seems you also have to add a blank like here.
The same applies for the OAS.
Reason: CI shows the following errors:
sklearn/covariance/_shrunk_covariance.py:docstring of sklearn.covariance._shrunk_covariance.LedoitWolf:117: WARNING: Bullet list ends without a blank line; unexpected unindent.
sklearn/covariance/_shrunk_covariance.py:docstring of sklearn.covariance._shrunk_covariance.OAS:117: WARNING: Bullet list ends without a blank line; unexpected unindent.
It pretty strictly follows some rules that you can look into here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect! Thanks a lot again
Some general information: when you go into the CI checks overview below, you find one that says "Check the rendered docs here!". In there, you can look into how the CI build the documentation for the changed files. For instance: modules/generated/sklearn.covariance.OAS.html [dev, stable] Where the first link is your branches version, the second is the main dev branch and the third link is the last releases scikit-learn version you can find on the website. It helps to check if everything went well. |
@StefanieSenger , all the checks have passed :) |
Reference Issues/PRs
PR #26927
What does this implement/fix? Explain your changes.
Added links to plot_covariance_estimation example in docstrings and userguide