Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

get_terminal

Get Terminal ID


Description

Get the ID of the basin outlet for each flowline.

Usage

get_terminal(x, outlets)

Arguments

x

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

outlets

IDs of outlet flowlines

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

NHDPlus Tools

v0.4.0
CC0
Authors
David Blodgett [aut, cre], Mike Johnson [ctb] (<https://orcid.org/0000-0002-5288-8350>)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.