Skip to content

REF: implement array_algos.putmask #38793

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 3 commits into from
Dec 30, 2020

Conversation

jbrockmendel
Copy link
Member

  • closes #xxxx
  • tests added / passed
  • passes black pandas
  • passes git diff upstream/master -u -- "*.py" | flake8 --diff
  • whatsnew entry

from pandas.core.dtypes.missing import isna_compat


def putmask_simple(values: ArrayLike, mask: np.ndarray, value: Any):
Copy link
Contributor

Choose a reason for hiding this comment

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

returns -> None

Copy link
Contributor

Choose a reason for hiding this comment

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

though maybe we should return the array for consistency with putmask_simple?

Copy link
Contributor

Choose a reason for hiding this comment

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

or rename to putmask_inplace

Copy link
Member Author

Choose a reason for hiding this comment

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

though maybe we should return the array for consistency with putmask_simple?

i think not returning anything makes it more obvious that it is inplace

or rename to putmask_inplace

sure

@jreback jreback added Internals Related to non-user accessible pandas implementation Refactor Internal refactoring of code labels Dec 30, 2020
@jreback jreback added this to the 1.3 milestone Dec 30, 2020
@jreback jreback merged commit 5af8a55 into pandas-dev:master Dec 30, 2020
@jbrockmendel jbrockmendel deleted the ref-putmask-3 branch December 30, 2020 20:03
luckyvs1 pushed a commit to luckyvs1/pandas that referenced this pull request Jan 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Internals Related to non-user accessible pandas implementation Refactor Internal refactoring of code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants