deltametrics.plan.compute_shoreline_distance¶
- deltametrics.plan.compute_shoreline_distance(shore_mask, origin=(0, 0), return_distances=False)¶
Compute mean and stddev distance from the delta apex to the shoreline.
Algorithm computes the mean distance from the delta apex/origin to all shoreline points.
Important
This calculation is subtly different than the “mean delta radius”, because the measurements are not sampled evenly along the opening angle of the delta.
Note
uses np.nanmean and np.nanstd.
- Parameters:
shore_mask (
ShorelineMask
,ndarray
) – Shoreline mask. Can be aShorelineMask
object, or a binarized array.origin (
list
,np.ndarray
, optional) – Determines the location from where the distance to all shoreline points is computed.return_distances (
bool
) – Whether to return the sorted line as a second argument. If True, aNx2
array of x-y points is returned. Default is False.
- Returns:
mean (
float
) – Mean shoreline distance.stddev (
float
) – Standard deviation of shoreline distance.distances (
np.ndarray
) – Ifreturn_distances
is True, then distance to each point along the shoreline is also returned as an array (i.e., 3 arguments are returned).
Examples
(
Source code
,png
,hires.png
)