Skip to content

indexing via any coordinate label values #4585

Answered by ahuang11
michaelaye asked this question in Q&A
Discussion options

You must be logged in to vote

At the moment, since lon and x coordinates share the same dimension, x, you can swap_dims so that lon becomes the dimension:
dem.swap_dims({'x': 'lon'}).sel(lat=slice(80, -80))
I believe there is an ongoing effort to refactor index
#475 (comment)

Replies: 1 comment 6 replies

Comment options

You must be logged in to vote
6 replies
@michaelaye
Comment options

@keewis
Comment options

@atreguier
Comment options

@michaelaye
Comment options

@dcherian
Comment options

Answer selected by michaelaye
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
5 participants