home / github / issues

Menu
  • Search all tables
  • GraphQL API

issues: 758165023

This data as json

id node_id number title user state locked assignee milestone comments created_at updated_at closed_at author_association active_lock_reason draft pull_request body reactions performed_via_github_app state_reason repo type
758165023 MDU6SXNzdWU3NTgxNjUwMjM= 4658 drop_sel indices in dimension that doesn't have coordinates? 193170 closed 0     3 2020-12-07T05:17:36Z 2021-01-18T23:59:09Z 2021-01-18T23:59:09Z NONE      

Is your feature request related to a problem? Please describe.

I am trying to drop particular indices from a dimension that doesn't have coordinates.

Following: drop_sel() documentation, but leaving out the coordinate labels: python data = np.random.randn(2, 3) ds = xr.Dataset({"A": (["x", "y"], data)}) ds.drop_sel(y=[1]) gives me an error.

Describe the solution you'd like

I would think drop_isel should exist and work in analogy to drop_sel as isel does to sel.

Describe alternatives you've considered

As far as I know, I could either create coordinates especially to in order to drop, or rebuild a new dataset. Both are not congenial. (I'd be grateful to know if there is actually a straightforward way to do this I've overlooked.

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/4658/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  completed 13221727 issue

Links from other tables

  • 2 rows from issues_id in issues_labels
  • 3 rows from issue in issue_comments
Powered by Datasette · Queries took 399.773ms · About: xarray-datasette