Skip to content

More builtin indexes #20

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 25 commits into from
Jul 9, 2025
Merged

Conversation

benbovy
Copy link
Member

@benbovy benbovy commented Jul 8, 2025

  • the default PandasIndex
  • stick coordinates together with PandasMultiIndex
  • large integer ranges with pandas.RangeIndex
  • float ranges with RangeIndex

benbovy and others added 16 commits July 8, 2025 20:18
Co-authored-by: Deepak Cherian <dcherian@users.noreply.github.com>
Co-authored-by: Deepak Cherian <dcherian@users.noreply.github.com>
Co-authored-by: Deepak Cherian <dcherian@users.noreply.github.com>
Co-authored-by: Deepak Cherian <dcherian@users.noreply.github.com>
Co-authored-by: Deepak Cherian <dcherian@users.noreply.github.com>
Co-authored-by: Deepak Cherian <dcherian@users.noreply.github.com>
Co-authored-by: Deepak Cherian <dcherian@users.noreply.github.com>
This is needed for pd.RangeIndex with "lazy" coordinate variable. This
will be needed for NDPointIndex too.

TODO: remove when next version of Xarray is released.
ds_air.sel(time="2013")
```

### Set indexes for non-dimension coordinates
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
### Set indexes for non-dimension coordinates
### Set indexes for any coordinate variable

Copy link
Contributor

@dcherian dcherian left a comment

Choose a reason for hiding this comment

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

Nice!

Would be good to link to RangeIndex and RasterIndex as examples in the CoordinateTransformIndex page. I think you have mentioned this already, but just writing it out as a reminder

benbovy and others added 3 commits July 9, 2025 09:35
Co-authored-by: Deepak Cherian <dcherian@users.noreply.github.com>
Co-authored-by: Deepak Cherian <dcherian@users.noreply.github.com>
@benbovy benbovy closed this Jul 9, 2025
@benbovy benbovy reopened this Jul 9, 2025
@benbovy
Copy link
Member Author

benbovy commented Jul 9, 2025

Thanks for the review @dcherian and @scottyhq !

I'm merging this now.

Would be good to link to RangeIndex and RasterIndex as examples in the CoordinateTransformIndex page. I think you have mentioned this already, but just writing it out as a reminder

Will do in a follow-up PR.

@benbovy benbovy merged commit b63f78a into xarray-contrib:main Jul 9, 2025
2 checks passed
@benbovy benbovy deleted the more-builtin-indexes branch July 9, 2025 07:52
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
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy