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

Period.start_time returns the same value as Period.end_time #1857

Closed
mlew opened this issue Sep 7, 2012 · 0 comments

Comments

@mlew
Copy link

commented Sep 7, 2012

If you create a Period object with a non-Day frequency, the start_time property incorrectly returns the end_time value.

ex:

In [1]: from pandas import *

In [2]: w = period_range('2012-8-20', '2012-9-10', freq='W-MON')

In [3]: w[0]
Out[3]: Period('14-Aug-2012/20-Aug-2012', 'W-MON')

In [4]: w[0].start_time
Out[4]: <Timestamp: 2012-08-20 00:00:00>

In [5]: w[0].end_time
Out[5]: <Timestamp: 2012-08-20 00:00:00>

In [6]: w[0].freq
Out[6]: 'W-MON'

The expected behavior would return a <Timestamp: 2012-08-14 00:00:00> object for the Period.start_time property.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.