Skip to content

[ENH] Categoricals improve #930

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

Merged
merged 39 commits into from
Oct 13, 2021
Merged

Conversation

samukweku
Copy link
Collaborator

@samukweku samukweku commented Sep 19, 2021

PR Description

Please describe the changes proposed in the pull request:

  • Drop As_Categorical helper function
  • Move checks into one function
  • Avoid copy of the DataFrame at the start of the function df = df.copy()

This PR resolves #927.

PR Checklist

Please ensure that you have done the following:

  1. PR in from a fork off your branch. Do not PR from <your_username>:dev, but rather from <your_username>:<feature-branch_name>.
  1. If you're not on the contributors list, add yourself to AUTHORS.rst.
  1. Add a line to CHANGELOG.md under the latest version header (i.e. the one that is "on deck") describing the contribution.
    • Do use some discretion here; if there are multiple PRs that are related, keep them in a single line.

Automatic checks

There will be automatic checks run on the PR. These include:

  • Building a preview of the docs on Netlify
  • Automatically linting the code
  • Making sure the code is documented
  • Making sure that all tests are passed
  • Making sure that code coverage doesn't go down.

Relevant Reviewers

Please tag maintainers to review.

@codecov
Copy link

codecov bot commented Sep 19, 2021

Codecov Report

Merging #930 (26d6b65) into dev (295af2b) will increase coverage by 0.01%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##              dev     #930      +/-   ##
==========================================
+ Coverage   95.95%   95.96%   +0.01%     
==========================================
  Files          19       19              
  Lines        2545     2530      -15     
==========================================
- Hits         2442     2428      -14     
+ Misses        103      102       -1     

Copy link
Member

@ericmjl ericmjl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a big PR and I was reviewing it at 11 pm at night. My review is necessarily not going to be complete.

I think we should get another pair of eyes on this PR before merging.

@samukweku
Copy link
Collaborator Author

@ericmjl @loganthomas made the edits .... ready for your review

@ericmjl
Copy link
Member

ericmjl commented Oct 13, 2021

It's been reviewed by two people, so I'm going to merge!

@ericmjl ericmjl merged commit 34935eb into pyjanitor-devs:dev Oct 13, 2021
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

Successfully merging this pull request may close these issues.

[ENH] improve encode_categoricals
3 participants