Skip to content

Commit 30bd733

Browse files
adapted docstring for extrapoaltion
1 parent 0457286 commit 30bd733

File tree

2 files changed

+14
-3
lines changed

2 files changed

+14
-3
lines changed

climada/engine/impact.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -516,7 +516,10 @@ def local_exceedance_impact(
516516
return periods larger than the Impact object's observed local return periods will be
517517
assigned the largest local impact, and return periods smaller than the Impact object's
518518
observed local return periods will be assigned 0. If set to "extrapolate", local
519-
exceedance impacts will be extrapolated (and interpolated). Defauls to "interpolate".
519+
exceedance impacts will be extrapolated (and interpolated). The extrapolation to
520+
large return periods uses the two highest impacts of the centroid and their return
521+
periods and extends the interpolation between these points to the given return period
522+
(similar for small return periods). Defauls to "interpolate".
520523
min_impact : float, optional
521524
Minimum threshold to filter the impact. Defaults to 0.
522525
log_frequency : bool, optional
@@ -648,6 +651,9 @@ def local_return_period(
648651
impacts will be assigned NaN, and threshold impacts smaller than the Impact
649652
object's local impacts will be assigned the smallest observed local return period.
650653
If set to "extrapolate", local return periods will be extrapolated (and interpolated).
654+
The extrapolation to large threshold impacts uses the two highest impacts of
655+
the centroid and their return periods and extends the interpolation between these
656+
points to the given threshold imapct (similar for small large threshold impacts).
651657
Defaults to "interpolate".
652658
min_impacts : float, optional
653659
Minimum threshold to filter the impact. Defaults to 0.

climada/hazard/base.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -509,8 +509,10 @@ def local_exceedance_intensity(
509509
periods larger than the Hazard object's observed local return periods will be assigned
510510
the largest local intensity, and return periods smaller than the Hazard object's
511511
observed local return periods will be assigned 0. If set to "extrapolate", local
512-
exceedance intensities will be extrapolated (and interpolated).
513-
Defauls to "interpolate".
512+
exceedance intensities will be extrapolated (and interpolated). The extrapolation to
513+
large return periods uses the two highest intensites of the centroid and their return
514+
periods and extends the interpolation between these points to the given return period
515+
(similar for small return periods). Defauls to "interpolate".
514516
min_intensity : float, optional
515517
Minimum threshold to filter the hazard intensity. If set to None, self.intensity_thres
516518
will be used. Defaults to None.
@@ -640,6 +642,9 @@ def local_return_period(
640642
intensities will be assigned NaN, and threshold intensities smaller than the Hazard
641643
object's local intensities will be assigned the smallest observed local return period.
642644
If set to "extrapolate", local return periods will be extrapolated (and interpolated).
645+
The extrapolation to large threshold intensities uses the two highest intensites of
646+
the centroid and their return periods and extends the interpolation between these
647+
points to the given threshold intensity (similar for small threshold intensites).
643648
Defaults to "interpolate".
644649
min_intensity : float, optional
645650
Minimum threshold to filter the hazard intensity. If set to None, self.intensity_thres

0 commit comments

Comments
 (0)