SumUpstreamArea returns a data frame with two columns containing SUBIDs and total upstream areas (in area units as provided in gd).
Upstream areas include areas of outlet SUBIDs.
Arguments
subid
Integer vector of SUBIDs to calculate upstream areas for (must exist in gd). If NULL, upstream areas for all
SUBIDs will be calculated.
gd
A data frame, containing 'SUBID', 'MAINDOWN', and 'AREA' columns, e.g. an imported 'GeoData.txt' file.
bd
A data frame, containing 'BRANCHID' and 'SOURCEID' columns, e.g. an imported 'BranchData.txt' file. Optional argument.
cl
Integer, number of processes to use for parallel computation. Set to 1 for serial computation. See parallel::detectCores().
progbar
Logical, display a progress bar while calculating upstream areas. Adds overhead to calculation time but useful if you want
HYPEtools to decide how long your coffee break should take.
Details
SumUpstreamArea sums upstream areas of all connected upstream SUBIDs, including branch connections in case of stream bifurcations
but not including potential irrigation links or groundwater flows.