-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
ENH: Add timetz attribute to DatetimeIndex and Timestamp #21358
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
Comments
Can I work on this? I'm new to working on pandas, but this seems like a fairly simple issue to get started with. |
So now However, there is a I would prefer instead having Thoughts? |
yeah that would be ok except it’s current a property - not sure we can change this |
It would be an API change; otherwise, I don't recall an internal reason why we can't break it. |
I am not sure this (adding a tz keyword) is worth the API change. Changing from a attribute to method is a quite big change, as every use of the current attribute would be impacted. |
Fair enough. Should we then mimic the standard library and add a |
I personally don't really care about adding it, but also won't object if others want it. |
@jquinon if you're interested to add a timetz property to |
If everyone is cool with it then sure. @jreback |
yep this sounds ok |
Currently
DatetimeIndex.time
returns a numpy array of localdatetime.time
s. In #18461, the resultingdatetime.time
s gained timezone information (but was an undocumented changed) and was subsequently reverted in #21281. Having.time
return timezone information would still be a nice enhancement.If we allow
DatetimeIndex.time
to return timezone information,timeseries.rst
will need to be changed since it currently indicates that.time
does not return timezone information.The text was updated successfully, but these errors were encountered: