Skip to content

ENH: add np.nanprod - #5418

Merged
charris merged 1 commit into
numpy:masterfrom
shoyer:nanprod
Jan 5, 2015
Merged

charris merged 1 commit into
numpy:masterfrom
shoyer:nanprod

Conversation

@shoyer

@shoyer shoyer commented Jan 3, 2015

Copy link
Copy Markdown
Member

This PR adds an implementation of nanprod.

The actual function is a two-liner adapted from nansum. Most of this PR
consists of documentation and tests (for which I took the opportunity to do
some consolidation).

A method with the same functionality exists in pandas, and I was surprised to
discover that it's not in numpy.

Comment thread numpy/lib/nanfunctions.py Outdated

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

sum -> product

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

fixed

@charris

charris commented Jan 5, 2015

Copy link
Copy Markdown
Member

LGTM modulo noun nitpick.

This PR adds an implementation of `nanprod`.

The actual function is a two-liner adapted from `nansum`. Most of this PR
consists of documentation and tests (for which I took the opportunity to do
some consolidation).

A method with the same functionality exists in pandas, and I was surprised to
discover that it's not in numpy.
@charris

charris commented Jan 5, 2015

Copy link
Copy Markdown
Member

Merged, thanks.

charris added a commit that referenced this pull request Jan 5, 2015
@charris
charris merged commit c6b8109 into numpy:master Jan 5, 2015
@shoyer shoyer mentioned this pull request Jun 23, 2015
@shoyer
shoyer deleted the nanprod branch March 16, 2016 17:44
pwolfram added a commit to pwolfram/numpy that referenced this pull request Mar 24, 2016
This PR adds an implementation of `nancumsum` and `nancumprod`.

The actual function is a two-liner adapted from `nansum`.

Its structure is adapted from PR: numpy#5418
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.

2 participants