home / github / pull_requests

Menu
  • GraphQL API
  • Search all tables

pull_requests: 143511107

This data as json

id node_id number state locked title user body created_at updated_at closed_at merged_at merge_commit_sha assignee milestone draft head base author_association auto_merge repo url merged_by
143511107 MDExOlB1bGxSZXF1ZXN0MTQzNTExMTA3 1597 closed 0 Add methods for combining variables of differing dimensionality 1386642 - [x] Closes #1317 - [x] Tests added / passed - [x] Passes ``git diff upstream/master | flake8 --diff`` - [x] Fully documented, including `whats-new.rst` for all changes and `api.rst` for new API While working on #1317, I settled upon combining `stack` and `to_array` to create two dimensional numpy arrays given an xarray Dataset. Unfortunately, `to_array` automatically broadcasts the variables of dataset, which is not always a desirable behavior. For instance, I was trying to combine precipitation (a horizontal field) and temperature (a 3D field) into one array. This PR enables this by adding two new methods to xarray: - `Dataset.stack_cat`, and - `DataArray.unstack_cat`. `stack_cat` uses `stack`, `expand_dims`, and `concat` to reshape a Dataset into a Dataarray with a helpful MultiIndex, and `unstack_cat` reverses the process. I implemented this functionality as a new method since `to_array` is such a clean method already. I really appreciate your thoughts on this. Thanks! cc @jhamman @shoyer 2017-09-27T22:01:57Z 2019-07-05T15:59:51Z 2019-07-05T00:32:51Z 2019-07-05T00:32:51Z 9c0fb6c6ca4a4da52ba5b0c2b17c12573a66def0     0 e08622a9dd78581c7051ca24d559410022022860 e26fbca88cb6c3b950bd52879a193de85feef7c8 CONTRIBUTOR   13221727 https://github.com/pydata/xarray/pull/1597  

Links from other tables

  • 0 rows from pull_requests_id in labels_pull_requests
Powered by Datasette · Queries took 152.479ms