Skip to content

Commit 289dab9

Browse files
baam25simoogrisel
andauthored
DOC Ensures that GammaRegressor passes numpydoc validation (scikit-learn#20973)
Co-authored-by: Olivier Grisel <olivier.grisel@ensta.org>
1 parent 9c84abd commit 289dab9

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

maint_tools/test_docstrings.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99

1010
# List of modules ignored when checking for numpydoc validation.
1111
DOCSTRING_IGNORE_LIST = [
12-
"GammaRegressor",
1312
"GaussianProcessRegressor",
1413
"GaussianRandomProjection",
1514
"GridSearchCV",

sklearn/linear_model/_glm/glm.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -606,6 +606,11 @@ class GammaRegressor(GeneralizedLinearRegressor):
606606
607607
.. versionadded:: 1.0
608608
609+
See Also
610+
--------
611+
PoissonRegressor : Generalized Linear Model with a Poisson distribution.
612+
TweedieRegressor : Generalized Linear Model with a Tweedie distribution.
613+
609614
Examples
610615
--------
611616
>>> from sklearn import linear_model
@@ -648,6 +653,7 @@ def __init__(
648653

649654
@property
650655
def family(self):
656+
"""Return the family of the regressor."""
651657
# Make this attribute read-only to avoid mis-uses e.g. in GridSearch.
652658
return "gamma"
653659

0 commit comments

Comments
 (0)