Assemble bathtub inundation model

assemble_net_model(
  pipes,
  structures,
  type = "elevation",
  use_raster_elevation = T,
  elev,
  elev_units = "m",
  min_elev_cutoff = -5,
  buffer = 0.5,
  interp_rnds = 5,
  guess_connectivity = T,
  up_condition = NULL,
  dn_condition = NULL,
  structure_condition = NULL,
  obstruction_keywords = NULL,
  obstruction_percent = F,
  overwrite = T,
  workspace
)

Arguments

pipes

A sf object denoting stormwater pipes. Result of setup_pipes

structures

A sf object denoting stormwater structures Result of setup_structures

type

Type of invert survey data. 'depth', 'elevation', or 'none'

use_raster_elevation

Extract elevation and use as surface elevations?

elev

RasterLayer DEM object for inundation modeling.Result of DEM_setup

elev_units

Units of elev values

min_elev_cutoff

Minimum cutoff for elevation values

buffer

Size of buffer for connecting structures to pipes

interp_rnds

Rounds of interpolation for missing invert elevations

guess_connectivity

Assume connectivity of pipes that overlap without nodes?

up_condition

Column name of upstream pipe condition. Either text of condition to be searched with obstruction_keywords or percent obstructions (obstruction_percent)

dn_condition

Column name of downstream pipe condition. Either text of condition to be searched with obstruction_keywords or percent obstructions (obstruction_percent)

structure_condition

Column name of structure condition. Either text of condition to be searched with obstruction_keywords or percent obstructions (obstruction_percent)

obstruction_keywords

Vector of keywords (in quotes) denoting obstruction to evaluate in up_condition, dn_condition, structure_condition

obstruction_percent

Should up_condition, dn_condition, and structure_condition, be evaluated as percent obstructed?

overwrite

Overwrite existing model files in the workspace? Default is TRUE. If set to FALSE, model will not be saved in output folder and will exist in memory (see load_model to load existing model).

workspace

bathtub workspace path

Value

An list of three sf objects denoting Pipes, Nodes, and Structures. Files are saved in '/model/' folder in workspace and by default overwrite existing model files

Examples

# bft_model <- assemble_net_model( # pipes = pipes_n, # structures = structures_n, # type = "none", # elev = bft_elev, # elev_units = "m", # use_raster_elevation = F, # buffer = 1, # guess_connectivity = T # )