MCPcopy Index your code
hub / github.com/pydata/xarray / rollback

Method rollback

xarray/coding/cftime_offsets.py:515–520  ·  view source on GitHub ↗

Roll date backward to nearest end of quarter

(self, date)

Source from the content-addressed store, hash-verified

513 return date + QuarterEnd(month=self.month)
514
515 def rollback(self, date):
516 """Roll date backward to nearest end of quarter"""
517 if self.onOffset(date):
518 return date
519 else:
520 return date - QuarterEnd(month=self.month)
521
522
523class YearOffset(BaseCFTimeOffset):

Callers

nothing calls this directly

Calls 2

QuarterEndClass · 0.85
onOffsetMethod · 0.45

Tested by

no test coverage detected