nhdR (version 0.5.3)

nhd_query: Select NHD features clipped by a circular buffer a coordinate pair

Description

Select NHD features clipped by a circular buffer a coordinate pair

Usage

nhd_query(lon, lat, dsn, buffer_dist = 0.05)

Arguments

lon

numeric longitude

lat

numeric latitude

dsn

character data source

buffer_dist

numeric buffer in units of coordinate degrees

Examples

Run this code
# NOT RUN {
wk <- wikilake::lake_wiki("Worden Pond")
qry <- nhd_query(wk$Lon, wk$Lat, dsn = c("NHDWaterbody", "NHDFlowline"))

plot(sf::st_geometry(qry$sp$NHDWaterbody), col = "blue")
plot(sf::st_geometry(qry$sp$NHDFlowline), col = "cyan", add = TRUE)
plot(qry$pnt, col = "red", pch = 19, add = TRUE)
axis(1); axis(2)
# }

Run the code above in your browser using DataLab