-
-
Notifications
You must be signed in to change notification settings - Fork 26k
DOC added intervals for parameters for 4 glm classes #22076
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
Conversation
@ogrisel Did you want to review this PR as well? It's (relatively) simpler than the other one on SGDClassifier. |
sklearn/linear_model/_glm/glm.py
Outdated
|
||
warm_start : bool, default=False | ||
If set to ``True``, reuse the solution of the previous call to ``fit`` | ||
as initialization for ``coef_`` and ``intercept_``. | ||
|
||
verbose : int, default=0 | ||
For the lbfgs solver set verbose to any positive number for verbosity. | ||
Values should be in the range `[1, inf)`. |
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.
Values should be in the range `[1, inf)`. | |
Values should be in the range `[0, inf)`. |
sklearn/linear_model/_glm/glm.py
Outdated
|
||
warm_start : bool, default=False | ||
If set to ``True``, reuse the solution of the previous call to ``fit`` | ||
as initialization for ``coef_`` and ``intercept_`` . | ||
|
||
verbose : int, default=0 | ||
For the lbfgs solver set verbose to any positive number for verbosity. | ||
Values should be in the range `[1, inf)`. |
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.
Values should be in the range `[1, inf)`. | |
Values should be in the range `[0, inf)`. |
Reminder to me:
|
sklearn/linear_model/_glm/glm.py
Outdated
@@ -72,6 +72,7 @@ class GeneralizedLinearRegressor(RegressorMixin, BaseEstimator): | |||
regularization strength. ``alpha = 0`` is equivalent to unpenalized | |||
GLMs. In this case, the design matrix `X` must have full column rank | |||
(no collinearities). | |||
Values should be in the range `[0.0, inf)`. |
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.
To be in line with #21946
Values should be in the range `[0.0, inf)`. | |
Values must be in the range `[0.0, inf)`. |
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.
LGTM. Thanks @reshamas Merging.
Reference Issues/PRs
References #21927 and #21946
What does this implement/fix? Explain your changes.
class GeneralizedLinearRegressor(RegressorMixin, BaseEstimator)
class PoissonRegressor(GeneralizedLinearRegressor)
class GammaRegressor(GeneralizedLinearRegressor)
class TweedieRegressor(GeneralizedLinearRegressor)
alpha
,max_iter
,tol
andverbose
Any other comments?
#DataUmbrella #postsprint