pywasp.lincom.get_return_wind#
- pywasp.lincom.get_return_wind(pewc, return_period=50, pewc_max_interval=None)[source]#
Use the Gumbel distribution to find the return wind and uncertainty
Warning
This function is experimental and its signature may change.
- Parameters:
pewc (
xarray.Dataset) – PyWAsP PEWC dataset with max_wspd variable, and only year and geospatial dimensionsreturn_period (
float, optional) – Return period in years to calculate the max wind speed and uncertainty By default 50 (years)pewc_max_interval (
float, optional) – Maximum interval in years, by default None
- Returns:
out_ds (
Dataset) – PyWAsP Dataset of the same spatial structure as pewc, containing the Gumbel distributions Alpha and Beta parameters, the extreme wind speed, and the uncertainty of the extreme wind speed.- Raises:
CoreError – If the Gumbel fit fails: pewc has fewer than two years, return_period is below one year, or pewc_max_interval is zero or negative.
Notes
pewc_max_interval is likely 1, the period of each year
Every condition that makes the fit fail applies to all points alike, so a failure raises instead of being reported per point. A point whose maxima contain NaN gets NaN results.