pyjanitor
pyjanitor copied to clipboard
[ENH] explicit default parameter for case_when
PR Description
Please describe the changes proposed in the pull request:
~~- standalone function (if_else
) that can be imported for use in pandas.assign~~
- explicit default parameter added
This PR resolves #1159 .
PR Checklist
Please ensure that you have done the following:
- [x] PR in from a fork off your branch. Do not PR from
<your_username>
:dev
, but rather from<your_username>
:<feature-branch_name>
.
- [x] If you're not on the contributors list, add yourself to
AUTHORS.md
.
- [ ] 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.
- @ericmjl
🚀 Deployed on https://deploy-preview-1165--pyjanitor.netlify.app
Codecov Report
Merging #1165 (dc12acc) into dev (4eaef97) will decrease coverage by
0.00%
. The diff coverage is100.00%
.
@@ Coverage Diff @@
## dev #1165 +/- ##
==========================================
- Coverage 97.96% 97.96% -0.01%
==========================================
Files 76 76
Lines 3395 3387 -8
==========================================
- Hits 3326 3318 -8
Misses 69 69
Two threads (https://github.com/pyjanitor-devs/pyjanitor/runs/8295244245, https://github.com/pyjanitor-devs/pyjanitor/runs/8295231459) CI failed due to new PR #1158.
case_when
testcases raised some errors like
=========================== short test summary info ============================
ERROR tests/functions/test_case_when.py - hypothesis.errors.InvalidArgument: ...
ERROR tests/functions/test_case_when.py - hypothesis.errors.InvalidArgument: ...
ERROR tests/functions/test_case_when.py - hypothesis.errors.InvalidArgument: ...
ERROR tests/functions/test_case_when.py - hypothesis.errors.InvalidArgument: ...
@thatlittleboy would you like to do the honors here? a -0.01% decrease in coverage is marginal, we can handle it :smile:
yep okies, merging