earthkit.climate.atmos.degree_days_exceedance_date¶
- earthkit.climate.atmos.degree_days_exceedance_date(tas: xarray.DataArray | str = 'tas', ds: xarray.Dataset | Any = None, *, thresh: Any = '0 degC', sum_thresh: Any = '25 K days', op: Literal['>', 'gt', '<', 'lt', '>=', 'ge', '<=', 'le'] = '>', after_date: str | None = None, never_reached: str | int | None = None, freq: str = 'YS', **kwargs: Any) Any¶
Degree day exceedance date.
The day of the year when the sum of degree days exceeds a threshold, occurring after a given date. Degree days are calculated above or below a given temperature threshold.
Units:
degree_days_exceedance_date: dimensionless
This function wraps xclim.indicators.atmos.degree_days_exceedance_date.
- Parameters:
tas (
xarray.DataArray | str) – Mean daily temperature.thresh (
Any) – Threshold temperature on which to base degree-days evaluation.sum_thresh (
Any) – Threshold of the degree days sum.op (
Literal[``’>’, ``'gt','<','lt','>=','ge','<=','le']) – If equivalent to ‘>’, degree days are computed as tas - thresh and if equivalent to ‘<’, they are computed as thresh - tas.after_date (
str | None) – Date at which to start the cumulative sum. In “MM-DD” format, defaults to the start of the sampling period.never_reached (
str | int | None) – What to do when sum_thresh is never exceeded. If an int, the value to assign as a day-of-year. If a string, must be in “MM-DD” format, the day-of-year of that date is assigned. Default (None) assigns “NaN”.freq (
str) – Resampling frequency. If after_date is given, freq should be annual.ds (
xarray.Dataset | Any) – Input dataset.**kwargs (
Any) – Additional keyword arguments.
- Returns:
The computed index.
- Return type:
Any