Skip to content

Commit 9d17fd2

Browse files
committed
deep
1 parent 298390f commit 9d17fd2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pandas/core/arrays/period.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ def _from_ordinals(cls, values, freq=None):
245245
@classmethod
246246
def _from_sequence(cls, scalars, dtype=None, copy=False):
247247
# type: (Sequence[Optional[Period]], Dtype, bool) -> PeriodArray
248-
return cls._complex_new(scalars, dtype=dtype, copy=copy)
248+
return cls._from_periods(scalars, dtype=dtype, copy=copy)
249249

250250
@classmethod
251251
def _from_factorized(cls, values, original):
@@ -328,7 +328,7 @@ def nbytes(self):
328328
return self._data.nbytes
329329

330330
def copy(self, deep=False):
331-
return self._from_ordinals(self._data.copy(), freq=self.freq)
331+
return self._from_ordinals(self._data.copy(deep=deep), freq=self.freq)
332332

333333
@classmethod
334334
def _concat_same_type(cls, to_concat):

0 commit comments

Comments
 (0)