We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1d94dd2 commit 8ef921fCopy full SHA for 8ef921f
pandas/tseries/index.py
@@ -716,13 +716,15 @@ def to_series(self, keep_tz=False):
716
717
If keep_tz is True:
718
719
- If the timezone is not set or is UTC, the resulting
+ If the timezone is not set, the resulting
720
Series will have a datetime64[ns] dtype.
721
- Otherwise the Series will have an object dtype.
+ Otherwise the Series will have an object dtype; the
722
+ tz will be preserved.
723
724
If keep_tz is False:
725
- Series will have a datetime64[ns] dtype.
726
+ Series will have a datetime64[ns] dtype. TZ aware
727
+ objects will have the tz removed.
728
729
Returns
730
-------
0 commit comments