This function estimates the course of streams and rivers from an elevation raster. It is based on the GRASS module r.stream.extract
, where more details can be found (see grassHelp("r.stream.extract")
)
Usage
# S4 method for class 'GRaster'
streams(
x,
accumulation = NULL,
depression = NULL,
flowThreshold = 1,
dirThreshold = 1,
montgomery = 0,
minLength = 1
)
Arguments
- x
A
GRaster
representing elevation.- accumulation
Either
NULL
(default) or a raster representing flow accumulation. If not supplied, an accumulation will created internally. You can generate an accumulation raster usingflow()
.- depression
Either
NULL
(default) or aGRaster
representing depressions (areas from which streams will not flow out of).- flowThreshold
Numeric > 0: Minimum threshold for a stream to be generated. The default is 1, which is not necessarily a reasonable value.
- dirThreshold
Numeric (default is
Inf
): When flow exceeds this threshold, its direction is estimated using a single-flow direction algorithm. Below this threshold, a multi-direction flow model is used. This is thed8cut
parameter inr.stream.extract
, and it is only used ifaccumulation
isNULL
. The default is 1, which is not necessarily a reasonable value.- montgomery
Numeric: The "Montgomery" exponent for slope, multiplied by accumulation as per
accumulation * slope^montgomery
. This value is then compared to the threshold to determine if it is sufficient. The default is 0 (i.e., no slope scaling).- minLength
Numeric: First-order streams less than this length are removed (units in cells). Default is 0 (no removal).
See also
flow()
, flowPath()
, GRASS manual for module r.stream.extract
(see grassHelp("r.stream.extract")
)