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

API: rename DataFrame.applymap -> DataFrame.map #52353

Closed
topper-123 opened this issue Apr 1, 2023 · 5 comments · Fixed by #52364
Closed

API: rename DataFrame.applymap -> DataFrame.map #52353

topper-123 opened this issue Apr 1, 2023 · 5 comments · Fixed by #52364
Labels
API Design Apply Apply, Aggregate, Transform, Map Deprecate Functionality to remove in pandas
Milestone

Comments

@topper-123
Copy link
Contributor

topper-123 commented Apr 1, 2023

I propose deprecating DataFrame.applymap and move its functionality to a new DataFrame.map method. The name map will better communicate that this is the DataFrame equivalent of Series.map. The current name can IMO be a bit confusing because the name contains both "apply" and "map", while just having "map" is clearer IMO.

See a discussion on this here.

CC @rhshadrach

@rhshadrach rhshadrach added API Design Apply Apply, Aggregate, Transform, Map labels Apr 2, 2023
@TeoSkondras
Copy link

take

@phofl phofl added the Deprecate Functionality to remove in pandas label Apr 2, 2023
@topper-123
Copy link
Contributor Author

topper-123 commented Apr 2, 2023

Hi @TeoSkondras. Thanks for wanting take take this, but I've made a branch already that is about to be ready to push to the pandas repository, so maybe not a good use of time to make a second pull requests on this.

@attack68
Copy link
Contributor

attack68 commented Apr 3, 2023

If this gets picked up pls ping me, since Styler.applymap would probably be better off remaining synchronised.

@topper-123
Copy link
Contributor Author

I've already made a PR (#52364) on this. Seem logical that the styler method has the same name as the frame method. I will ping you when this is merged no problem.

@rhshadrach rhshadrach added this to the 2.1 milestone Apr 16, 2023
@topper-123
Copy link
Contributor Author

This has been merged now in #52364 @attack68.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API Design Apply Apply, Aggregate, Transform, Map Deprecate Functionality to remove in pandas
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants