Skip to content

DOC: Remove outdated comment, use DateOffset instead of BaseOffset in docs #61097

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

Merged
merged 1 commit into from
Mar 24, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions pandas/_libs/tslibs/period.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -1752,9 +1752,6 @@ cdef class _Period(PeriodMixin):
def __cinit__(self, int64_t ordinal, BaseOffset freq):
self.ordinal = ordinal
self.freq = freq
# Note: this is more performant than PeriodDtype.from_date_offset(freq)
# because from_date_offset cannot be made a cdef method (until cython
# supported cdef classmethods)
self._dtype = PeriodDtypeBase(freq._period_dtype_code, freq.n)

@classmethod
Expand Down Expand Up @@ -1913,7 +1910,7 @@ cdef class _Period(PeriodMixin):

Parameters
----------
freq : str, BaseOffset
freq : str, DateOffset
The target frequency to convert the Period object to.
If a string is provided,
it must be a valid :ref:`period alias <timeseries.period_aliases>`.
Expand Down Expand Up @@ -2599,7 +2596,7 @@ cdef class _Period(PeriodMixin):

Parameters
----------
freq : str, BaseOffset
freq : str, DateOffset
Frequency to use for the returned period.

See Also
Expand Down
Loading