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

BUG: Fix .iat indexing with a PeriodIndex GH4390 #4394

Merged
merged 1 commit into from Jul 30, 2013

Conversation

jreback
Copy link
Contributor

@jreback jreback commented Jul 28, 2013

closes #4390

Interesting fixed this as well (only affects get)

In [1]: s = Series(randn(10),date_range('20130101',periods=10))

In [2]: s[0]
Out[2]: 1.1755210838393764

In [3]: s
Out[3]: 
2013-01-01    1.175521
2013-01-02    0.007910
2013-01-03   -1.235595
2013-01-04    0.478245
2013-01-05   -0.140616
2013-01-06   -2.317585
2013-01-07    0.609555
2013-01-08    1.204914
2013-01-09   -0.589893
2013-01-10   -2.017237
Freq: D, dtype: float64

In [4]: s[-1]
Out[4]: -2.0172365222181257

In [5]: s[-5]
Out[5]: -2.3175847263447964

This was before this PR returning None (while s[-5] worked)

In [6]: s.get(-5)

@cpcloud
Copy link
Member

cpcloud commented Jul 29, 2013

@jreback waiting for @jtratner b4 merging this?

@jreback
Copy link
Contributor Author

jreback commented Jul 29, 2013

yep

     Series.get with negative indexers returns the same as []
jreback added a commit that referenced this pull request Jul 30, 2013
BUG: Fix .iat indexing with a PeriodIndex GH4390
@jreback jreback merged commit fcaf9a6 into pandas-dev:master Jul 30, 2013
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.

BUG: iat/at broken for PeriodIndex
2 participants