-
Notifications
You must be signed in to change notification settings - Fork 941
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 pandas FutureWarnings in calls to .groupby() #1164
Fix pandas FutureWarnings in calls to .groupby() #1164
Conversation
…rrent behavior and silence the pandas FutureWarning Signed-off-by: Dylan W <139509928+dw-610@users.noreply.github.com>
@@ -256,7 +256,7 @@ | |||
}, | |||
{ | |||
"data": { |
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.
can you avoid making changes to the "data" field?
you can do by checking out the remote version of this file and only changing the groupby 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.
Thanks for these changes @dw-610 They look good to merge, but there's a minor comment I made inline. Can you take a look at that and avoid major changes to the notebook file?
…ta' field Signed-off-by: Dylan W <139509928+dw-610@users.noreply.github.com>
…rning Signed-off-by: Dylan W <139509928+dw-610@users.noreply.github.com>
722ca98
to
58960e0
Compare
Thanks for the feedback @amit-sharma The issue should be resolved now. |
Thanks! @all-contributors please add @dw-610 for code |
I've put up a pull request to add @dw-610! 🎉 |
Problem
Currently, with pandas version 2.2.2, calls to .groupby() raise the warning below:
FutureWarning: The default of observed=False is deprecated and will be changed to True in a future version of pandas. Pass observed=False to retain current behavior or observed=True to adopt the future default and silence this warning.
Solution
To retain current behavior and silence this warning, observed=False was added to all calls to .groupby()