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
FIX expose fill_value in IterativeImputer #25232
Conversation
fill_value
in IterativeImputer
fill_value
in IterativeImputer
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.
We need to add a test to check that we get the proper behaviour.
Since we expose intital_imputer_
we can check that the fill_value
is wired to it.
We also need an entry in the v1.3.rst
changelog file.
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>
@glemaitre Thanks for the feedback. Have your concerns been sufficiently addressed? |
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.
Otherwise, it starts to look good.
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>
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
Co-authored-by: Tim Head <betatim@gmail.com>
@glemaitre, do you have any idea why these tests are failing? I ran pytest and flake8, and neither reported an issue. |
I would assume that we need to merge |
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 @ValueInvestorThijs
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com> Co-authored-by: Tim Head <betatim@gmail.com>
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com> Co-authored-by: Tim Head <betatim@gmail.com>
Reference Issues/PRs
Fixes #25052
What does this implement/fix? Explain your changes.
Adds the parameter
fill_value
toIterativeImputer
.Any other comments?
@betatim suggested adding support for passing any imputer as
initial_strategy
. However, I purposefully dismissed this, for the following two reasons:add_indicator
toTrue
in an imputer passed asinitial_strategy
,IterativeImputer
would probably run into issues.IterativeImputer
could be described as a general imputer, i.e., one that is able to leverage any regressor or classifier for imputation purposes, and thereby making other imputers redundant.Lastly, additional to the delay resulting from my exams, this was my first time contributing to open source (and in the process, I crashed my PC). Therefore, I am interested to see whether my work meets the sklearn standard.
Cheers.