Skip to contents

Calculates the average slope of the FLYS water level at MQ computed by hyd1d::waterLevelFlys3() for the indexed hectometer polygon of sf.afe_csa and its specified surrounding as quotient of water level difference divided by distance.

Usage

getSlope(x, b, bu = b)

Arguments

x

must be a single integer indexing one hectometer polygon of sf.afe_csa along the River Elbe. x must be element of seq(from = 1, to = length(sf.afe_csa), by = 1).

b

must be a single numeric specifying a buffersize to be included for the axis length computations around the indexed hectometer in m.

bu

is an optional single numeric specifying a separate upstream buffersize to be included for the axis length computations around the indexed hectometer in m (default = b).

Value

numeric.

Examples

   getSlope(3900, 200)
#> [1] -0.0001490645
   getSlope(3963, 200)
#> [1] -0.0001494782