get_terminal: Get Terminal ID (DEPRECATED)

View source: R/get_paths.R

get_terminalR Documentation

Get Terminal ID (DEPRECATED)

Description

Get the ID of the basin outlet for each flowline. This function has been deprecated in favor of get_sorted.

Usage

get_terminal(x, outlets)

Arguments

x

two column data.frame with IDs and toIDs. Names are ignored.

outlets

IDs of outlet flowlines

Value

data.frame containing the terminal ID for each outlet

Examples

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

fl <- dplyr::select(prepare_nhdplus(walker_flowline, 0, 0),
                    ID = COMID, toID = toCOMID)

outlet <- fl$ID[which(!fl$toID %in% fl$ID)]

get_terminal(fl, outlet)


nhdplusTools documentation built on June 22, 2024, 10:36 a.m.