We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 07f38ef commit 071923dCopy full SHA for 071923d
pandas/core/indexes/accessors.py
@@ -77,7 +77,6 @@ def _delegate_property_get(self, name):
77
78
# blow up if we operate on categories
79
if self.orig is not None:
80
- result = take_1d(result, self.orig.cat.codes)
81
index = self.orig.index
82
else:
83
index = self._parent.index
@@ -324,10 +323,7 @@ def __new__(cls, data):
324
323
325
orig = data if is_categorical_dtype(data) else None
326
if orig is not None:
327
- data = Series(
328
- orig.values.astype("datetime64[ns]"), name=orig.name, copy=False
329
- )
330
-
+ data = Series(orig.values.to_list(), name=orig.name, copy=False)
331
try:
332
if is_datetime64_dtype(data.dtype):
333
return DatetimeProperties(data, orig)
0 commit comments