river class
river-class.Rd
A river
object contains information on river attributes at different aggregation levels. It can represent a real river network
(obtained via extract_river
) or an optimal channel network (obtained via OCNet::create_OCN
).
The content of a river
object can be treated as a list, hence its objects and sublists can be accessed with both the $
and @
operators.
For information on the aggregation levels and on the content of a
river
object, see OCNet::OCNet-package
.
Examples
if (FALSE) { # interactive() && traudem::can_register_taudem()
fp <- system.file("extdata/wigger.tif", package="rivnet")
r <- extract_river(outlet=c(637478,237413),
DEM=fp)
show(r)
names(r)
# extract or replace parts of a river object
r$dimX
r@dimX
dim <- r[["dimX"]]
r$dimX <- 1
r[["dimX"]]
r[["dimX"]] <- dim
}