pandas.tseries.offsets.Day.is_on_offset#
- Day.is_on_offset(dt)#
Return boolean whether a timestamp intersects with this frequency.
For Day offset, this method always returns True, since every timestamp can be considered as intersecting with a day-based frequency.
- Parameters:
- dtdatetime
Timestamp to check.
- Returns:
- bool
Always True for Day offset.
See also
DateOffset.is_on_offsetCheck if timestamp intersects with frequency.
BusinessDay.is_on_offsetCheck if timestamp is on business day.
Examples
>>> from pandas.tseries.offsets import Day >>> ts = pd.Timestamp(2022, 8, 5, 15, 30) >>> day = Day() >>> day.is_on_offset(ts) True