select_point_overlay function

Select features clipped by a point buffer around a point

Select features clipped by a point buffer around a point

select_point_overlay(pnt, sp, buffer_dist = units::as_units(4.75, "km"))

Arguments

  • pnt: geographic point of class sfc
  • sp: list of sf data frames
  • buffer_dist: numeric buffer with specified units

Returns

A list of sf spatial objects

Examples

## Not run: wk <- wikilake::lake_wiki("Gull Lake (Michigan)") pnt <- sf::st_sfc(sf::st_point(c(wk$Lon, wk$Lat))) sf::st_crs(pnt) <- 4326 sp <- lapply(c("NHDWaterbody", "NHDFlowLine"), function(x) nhd_plus_load(vpu = 4, dsn = x)) names(sp) <- c("NHDWaterbody", "NHDFlowLine") qry <- select_point_overlay(pnt = pnt, sp = sp) plot(qry$NHDWaterbody$geometry, col = "blue") plot(qry$NHDFlowLine$geometry, col = "cyan", add = TRUE) ## End(Not run)

Other functions in nhdR

Related functions from the same R package

  • Maintainer: Jemma Stachelek
  • License: GPL
  • Last published: 2023-08-12