Skip to content

Add ptp#2691

Merged
jcrist merged 4 commits intodask:masterfrom
jakirkham:add_ptp
Sep 20, 2017
Merged

Add ptp#2691
jcrist merged 4 commits intodask:masterfrom
jakirkham:add_ptp

Conversation

@jakirkham
Copy link
Copy Markdown
Member

@jakirkham jakirkham commented Sep 20, 2017

Fix #2687

Adds a Dask Array implementation of ptp. Simply takes the difference between the max and the min of the Dask Array. Also supports an optional axis argument. In the default case acts on the flattened array. Documents the function and provides some tests to make sure it behaves ok. Skips implementing the out argument as it's unclear what value this provides for Dask Arrays.

Implements `ptp` for Dask Arrays. Basically just the difference between
the `max` and `min` with an optional `axis` argument. Skipped providing
`out` even though NumPy provides it. Not sure that it makes much sense
to have `out` for Dask Arrays or that it is of any value.
Provide some test cases for the Dask Array `ptp` implementation with
different `axis` arguments.
@jakirkham jakirkham mentioned this pull request Sep 20, 2017
@mrocklin
Copy link
Copy Markdown
Member

Looks perfect to me

@jcrist jcrist merged commit 3725ac2 into dask:master Sep 20, 2017
@jcrist
Copy link
Copy Markdown
Member

jcrist commented Sep 20, 2017

Thanks @jakirkham.

@jakirkham
Copy link
Copy Markdown
Member Author

Thanks guys.

@jakirkham jakirkham deleted the add_ptp branch September 20, 2017 20:39
fujiisoup pushed a commit to fujiisoup/dask that referenced this pull request Feb 3, 2018
* Add ptp

Implements `ptp` for Dask Arrays. Basically just the difference between
the `max` and `min` with an optional `axis` argument. Skipped providing
`out` even though NumPy provides it. Not sure that it makes much sense
to have `out` for Dask Arrays or that it is of any value.

* Export ptp in Dask Array's public API

* Document ptp in Dask Array API docs

* Test ptp

Provide some test cases for the Dask Array `ptp` implementation with
different `axis` arguments.
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.

3 participants