Skip to content

Use kwargs in case_when #1221

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

Closed
samukweku opened this issue Dec 10, 2022 · 1 comment
Closed

Use kwargs in case_when #1221

samukweku opened this issue Dec 10, 2022 · 1 comment

Comments

@samukweku
Copy link
Collaborator

samukweku commented Dec 10, 2022

Brief Description

Use kwargs instead of args, this has the added benefit of allowing multiple assignments

Example API

df.case_when(a=(cond1,val1, default), b=(cond2,val2, default),...)
@samukweku
Copy link
Collaborator Author

Closing. .. there is a WIP in pandas : pandas-dev/pandas#50343

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

1 participant