-
Notifications
You must be signed in to change notification settings - Fork 15
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
Create BaseDropOriginalMixin Class #248
Conversation
Linting errors caused by resolution of merge conflicts, will set up another |
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.
Looks good, couple of suggestions I would like to see addressed but both minor.
tubular/nominal.py
Outdated
@@ -1246,9 +1247,12 @@ def transform(self, X: pd.DataFrame) -> pd.DataFrame: | |||
) | |||
|
|||
# Drop original columns |
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 think the comment here could do with extending with ' if self.drop_original is true' as the functionality is not obvious without reading the called function.
assert ("a" in df_transformed.columns.to_numpy()) and ( | ||
"b" in df_transformed.columns.to_numpy() | ||
), "original columns not kept" | ||
|
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.
S - ideally would also have a test that other columns in X are unaffected when dropping columns addressed by the transformer.
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.
Thanks for reviewing David, have pushed recommend changes :)
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.
Looks good! Thanks 🙏
As per ticket here