as.catchment_system | R Documentation |
Creates system of catchments with reservoirs.
as.catchment_system(...)
... |
Objects of |
An error occurs if a given downstream catchment is not available.
data_catch = data.frame(DTM = seq(as.Date("1982-11-01"), length.out = 7, by = "day"), PET = rep(0.5, 7), R = rep(24 * 3.6, 7), P = rep(1, 7))
res_data_c1 = data.frame(
storage = c(1e7, 1e7, 1e7), area = c(1e4, 1e4, 1e4), part = c(0.25, 0.25, 0.5), branch_id = c("main", "lateral", "lateral"), id = c("M1", "L1", "L2"))
branches = list(main = list(down_id = NA), lateral = list(down_id = "main", connect_to_part = 0.8))
res_data_c2 = res_data_c1
res_data_c2$storage = res_data_c2$storage * 2
catch1 = as.catchment(id = "C1", down_id = "C2", data = data_catch, area = 100, res_data = res_data_c1, branches = branches, main_branch = "main")
catch2 = as.catchment(id = "C2", down_id = NA, data = data_catch, area = 200, res_data = res_data_c2, branches = branches, main_branch = "main")
catch_system = as.catchment_system(catch1, catch2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.