Learn R Programming

nhdplusTools (version 1.3.2)

get_wb_outlet: Get Waterbody Outlet

Description

Get Waterbody Outlet

Usage

get_wb_outlet(lake_id, network)

Value

sf data.frame with single record of network COMID associated with most-downstream reach in the NHD Waterbody

Arguments

lake_id

integer COMID (or character permanent identifier for hi res) of lake.

network

data.frame of network features containing wbareacomi, and Hydroseq

Examples

Run this code
# \donttest{

source(system.file("extdata/sample_data.R", package = "nhdplusTools"))

fline <- sf::read_sf(sample_data, "NHDFlowline_Network")
wtbdy <- sf::read_sf(sample_data, "NHDWaterbody")

lake_COMID <- wtbdy$COMID[wtbdy$GNIS_NAME=='Lake Mendota 254']

get_wb_outlet(13293262, fline)

# }

Run the code above in your browser using DataLab