#catchstats
catchstats includes a number of functions written by Chris Walsh and Nick Bond for working with nested catchment or river-network data tables, to identify all upstream areas, all downstream areas, segments or sub-catchments between catchment pairs etc. There are also functions for intersecting raster and polygon layers to aggregate values downstream through a catchment. All of these functions require a dataframe that includes a unique catchment identifier field (column) and a field (column) identifying the next downstream catchment identity. Together these are referred to as a ‘hierarchy table’, and are included with many DEM derived stream networks.
#Installation To install run the following code:
# install devtools pacakge
install.packages(c("devtools"))
# install catchstats package
devtools::install_github("nickbond/catchstats")
# Remove the package zip after installation
unlink("catchstats.zip")
#load library
library(catchstats)
#Example
#To be completed
#Developer Nick Bond [email protected]