This function takes backup data frame output from flow_mapper() and form_mapper() calculates hillslope, channel segments and impoundment spatial entities required for input in to WEPP (Water Erosion and Prediction Project) (among other metrics). Based on FacetMapR by R. A. (Bob) MacMillan, LandMapper Environmental Solutions.

wepp_mapper(
  folder,
  chan_length = 200,
  upslope_threshold = 300,
  clean = FALSE,
  resume = NULL,
  log = TRUE,
  verbose = FALSE,
  quiet = FALSE,
  debug = FALSE
)

Arguments

folder

Character. Location of flow_mapper() output

chan_length

Numeric. Channel length maximum length. Used to split channels into segments

upslope_threshold

Numeric. Threshold of upslope cells to define channel cells. #' Cells with an upslope value larger than this are considered channel cells

clean

Logical. Remove all output files from previous runs in this folder?

resume

Character. From which stage should the run be resumed? (see

log

Logical. Create log file recording progress?

verbose

Logical. Output extra progress messages.

quiet

Logical. Suppress all messages.

debug

Logical. If TRUE, output files contain intermediate columns useful for debugging (e.g., 'buffer', 'seqno_buffer', etc.) Default FALSE.

Examples


if (FALSE) {
# First need to run flow_mapper()
flow_mapper(file = system.file("extdata", "testELEV.dbf", package = "LITAP"),
           out_folder = "./testELEV/", nrow = 90, ncol = 90, grid = 5)

# Now can run wepp_mapper()
wepp_mapper(folder = "./testELEV/")
}