Skip to content
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

ENH: Add IntervalIndex.is_overlapping #23309

Closed
jschendel opened this issue Oct 24, 2018 · 0 comments · Fixed by #23327
Closed

ENH: Add IntervalIndex.is_overlapping #23309

jschendel opened this issue Oct 24, 2018 · 0 comments · Fixed by #23327
Labels
Enhancement Interval Interval data type
Milestone

Comments

@jschendel
Copy link
Member

This is needed in the get_indexer implementation for the new IntervalIndex behavior, as an overlapping IntervalIndex may return non-unique indices for a given query. Note that this equivalent to other indexes checking is_unique as part of get_indexer, which does not suffice for IntervalIndex for the aforementioned reason. Behavior and API design would be comparable to is_non_overlapping_monotonic.

My plan is to implement this within the IntervalTree to take advantage of some cached sorting that it performs, so it would not be implemented for IntervalArray (we don't build an IntervalTree there, as IntervalArray is mutable, and doesn't need indexing methods). This could be implemented for IntervalArray if need be but might not be quite as performant.

@jschendel jschendel added Enhancement Interval Interval data type labels Oct 24, 2018
@jschendel jschendel added this to the 0.24.0 milestone Oct 24, 2018
@jreback jreback modified the milestones: 0.24.0, Contributions Welcome Nov 25, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement Interval Interval data type
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants