-
-
Notifications
You must be signed in to change notification settings - Fork 18.7k
ENH - Index set operation modifications to address issue #23525 #23538
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
Changes from 1 commit
c2cf269
435e50f
4922fd3
5e528a1
cdaa5b0
40d57ec
11fd041
8f0ace3
8364c2e
ab329a9
93486ad
e435e4c
b9787b8
2241b65
4daf360
6e5a52b
d344e11
b339bd1
85e2db7
cf34960
7150c22
fbb3743
5aa41f6
02d7a3b
558e182
706f973
2ccab59
c70f1c0
edb7e9c
84bfbda
aba75fe
fc9f138
69cce99
fdfc7d7
42ca70e
5b25645
9b1ee7f
fdf9b71
1de3cc8
8ed1093
77ca3a3
5921038
3b94e3b
fd4510e
345eec1
265a7ee
5de3d57
6d82621
0af8a24
5a87715
a4f9e78
c3c0caa
0bcbdf4
c410625
6bb054f
aea731c
b5938fc
25452fc
0b97a79
bf11c6f
6fd941d
32037b5
8870006
1d12bc9
92f6707
fbf3242
38d9f74
b9e7b18
69aaa93
b57160a
daa1287
54898c1
fa839a9
a36f475
b840f49
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
…empty indexes, and allow more cross index operaions
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1030,7 +1030,14 @@ def equals(self, other): | |
|
||
def _setop(op_name): | ||
def func(self, other): | ||
other = self._as_like_interval_index(other) | ||
try: | ||
jschendel marked this conversation as resolved.
Show resolved
Hide resolved
|
||
other = self._as_like_interval_index(other) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It looks like There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. agreed and done, also allows me to get rid of the try except that really should have just been an if condition. |
||
except (TypeError, ValueError): | ||
# Currently this will cause difference operations to return | ||
# object dtype as opposed to IntervalIndex, unlike other Index | ||
# objects that return the same type when using `difference` on | ||
# mismatched types | ||
return getattr(self.astype('O'), op_name)(other) | ||
ms7463 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
# GH 19016: ensure set op will not return a prohibited dtype | ||
subtypes = [self.dtype.subtype, other.dtype.subtype] | ||
|
Uh oh!
There was an error while loading. Please reload this page.