Skip to content
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

DeprecationWarning: DataFrameGroupBy.apply #64

Open
paulschreiber opened this issue Apr 17, 2024 · 0 comments
Open

DeprecationWarning: DataFrameGroupBy.apply #64

paulschreiber opened this issue Apr 17, 2024 · 0 comments
Assignees

Comments

@paulschreiber
Copy link
Member

paulschreiber commented Apr 17, 2024

Fix the code causing this warning:

  /home/runner/work/soil-id-algorithm/soil-id-algorithm/soil_id/utils.py:2162: DeprecationWarning: 
DataFrameGroupBy.apply operated on the grouping columns. This behavior is deprecated, and in a future 
version of pandas the grouping columns will be excluded from the operation. Either pass 
`include_groups=False` to exclude the groupings or explicitly select the grouping columns after groupby to 
silence this warning.
    result = df.groupby("compname_grp").apply(process_group).reset_index(drop=True)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants