split_catchment_divide: Split Catchment Divides

View source: R/split_catchment.R

split_catchment_divideR Documentation

Split Catchment Divides

Description

A catchment-divide splitting algorithm that works with a D8 flow direction grid and the output of nhdplus_refactor. See Vignette for examples.

Usage

split_catchment_divide(
  catchment,
  fline,
  fdr,
  fac,
  lr = FALSE,
  min_area_m = 800,
  snap_distance_m = 100,
  simplify_tolerance_m = 40,
  vector_crs = NULL
)

Arguments

catchment

sf data.frame with one catchment divide

fline

sf data.frame with one or more flowline segments in upstream downstream order.

fdr

character path to flow direction that fully covers the catchment

fac

character path to flow accumulation that fuller covers the catchment

lr

boolean should catchments be split along the left/right bank?

min_area_m

minimum area in m^2 to filter out slivers (caution, use with care!!)

snap_distance_m

distance in meters to snap SpatRaster generated geometry to polygon geometry

simplify_tolerance_m

dTolerance in meters for simplification of grid-cell based polygons

vector_crs

any object compatible with sf::st_crs. Used for vector-based calculations in case that fdr projection is not suitable (e.g. lon/lat) – must result in units of meters.

Value

Split catchment divides as an sfc geometry.


dblodgett-usgs/hyRefactor documentation built on Oct. 14, 2024, 12:59 p.m.