earthkit.climate.atmos.precipitation.days_over_precip_thresh¶
- earthkit.climate.atmos.precipitation.days_over_precip_thresh(pr: xarray.DataArray | str = 'pr', pr_per: xarray.DataArray | str = 'pr_per', ds: xarray.Dataset | Any = None, *, thresh: Any = '1 mm/day', freq: str = 'YS', bootstrap: bool = False, op: Literal['>', '>=', 'gt', 'ge'] = '>', **kwargs: Any) Any¶
Number of days with precipitation above a given percentile.
Number of days in a period where precipitation is above a given percentile, calculated over a given period and a fixed threshold.
Units:
days_over_precip_thresh: days
This function wraps xclim.indicators.atmos.days_over_precip_thresh.
- Parameters:
pr (
xarray.DataArray | str) – Mean daily precipitation flux.pr_per (
xarray.DataArray | str) – Percentile of wet day precipitation flux. Either computed daily (one value per day of year) or computed over a period (one value per spatial point).thresh (
Any) – Precipitation value over which a day is considered wet.freq (
str) – Resampling frequency.bootstrap (
bool) – Flag to run bootstrapping of percentiles. Used by percentile_bootstrap decorator. Bootstrapping is only useful when the percentiles are computed on a part of the studied sample. This period, common to percentiles and the sample must be bootstrapped to avoid inhomogeneities with the rest of the time series. Do not enable bootstrap when there is no common period, otherwise it will provide the wrong results. Note that bootstrapping is computationally expensive.op (
Literal[``’>’, ``'>=','gt','ge']) – Comparison operation. Default: “>”.ds (
xarray.Dataset | Any) – Input dataset.**kwargs (
Any) – Additional keyword arguments.
- Returns:
The computed index.
- Return type:
Any