get_node | R Documentation |
Given one or more flowlines, returns a particular node from the flowline.
get_node(x, position = "end")
x |
sf data.frame with one or more flowlines |
position |
character either "start" or "end" |
sf data.frame containing requested nodes
source(system.file("extdata/sample_data.R", package = "nhdplusTools")) fline <- sf::read_sf(sample_data, "NHDFlowline_Network") start <- get_node(fline, "start") end <- get_node(fline, "end") plot(sf::st_zm(fline$geom), lwd = fline$StreamOrde, col = "blue") plot(sf::st_geometry(start), add = TRUE) plot(sf::st_zm(fline$geom), lwd = fline$StreamOrde, col = "blue") plot(sf::st_geometry(end), add = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.