Skip to content

BUG: datetime ops with non-unique indexes is buggy #8363

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

Closed
jreback opened this issue Sep 22, 2014 · 1 comment · Fixed by #8364
Closed

BUG: datetime ops with non-unique indexes is buggy #8363

jreback opened this issue Sep 22, 2014 · 1 comment · Fixed by #8364
Labels
Bug Datetime Datetime data dtype Timedelta Timedelta data type
Milestone

Comments

@jreback
Copy link
Contributor

jreback commented Sep 22, 2014

from SO

In [3]:       df = DataFrame({'A' : np.arange(5), 'B' : np.arange(1,6)},index=[2,2,3,3,4])

In [4]:   df.B-df.A
Out[4]: 
2    1
2    1
3    1
3    1
4    1
dtype: int64

In [5]:        df = DataFrame({'A' : date_range('20130101',periods=5), 'B' : date_range('20130101 09:00:00', periods=5)},index=[2,2,3,3,4])

In [6]:   df.B-df.A
Out[6]: 
2     0 days 09:00:00
2   -1 days +09:00:00
2     1 days 09:00:00
2     0 days 09:00:00
3     0 days 09:00:00
3   -1 days +09:00:00
3     1 days 09:00:00
3     0 days 09:00:00
4     0 days 09:00:00
dtype: timedelta64[ns]
@jreback jreback added Bug Datetime Datetime data dtype Timedelta Timedelta data type labels Sep 22, 2014
@jreback jreback added this to the 0.15.0 milestone Sep 22, 2014
@bgbg
Copy link

bgbg commented Sep 22, 2014

jreback: you are awom

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Datetime Datetime data dtype Timedelta Timedelta data type
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants