get_area_osm_data: Get Open Street Map features for area

View source: R/get_area_osm_data.R

get_area_osm_dataR Documentation

Get Open Street Map features for area

Description

[Deprecated]

This function is deprecated because the functionality has been incorporated into the improved getdata::get_osm_data() function which uses a similar set of parameters.

Wraps osmdata functions.

Usage

get_area_osm_data(
  area = NULL,
  bbox = NULL,
  key,
  value = NULL,
  return_type = c("osm_polygons", "osm_points", "osm_lines", "osm_multilines",
    "osm_multipolygons"),
  dist = NULL,
  diag_ratio = NULL,
  asp = NULL,
  crop = TRUE,
  trim = FALSE,
  crs = pkgconfig::get_config("mapbaltimore.crs", 2804)
)

Arguments

area

sf object. If multiple areas are provided, they are unioned into a single sf object using sf::st_union()

bbox

bbox object to buffer and/or adjust. If an area is provided, any bbox is ignored.

key

feature key for overpass query. If key is "building" and value is NULL, a preset list of tag values will be used to return all available buildings in the bounding box.

value

for feature key; can be negated with an initial exclamation mark, value = "!this", and can also be a vector, value = c ("this", "that").

return_type

Character vector length 1 with geometry type to return. Defaults to returningpolygons. Set to NULL to return all types.

dist

buffer distance in meters. Optional.

diag_ratio

ratio to set map extent based diagonal distance of area's bounding box. Ignored when dist is provided.

asp

Aspect ratio of width to height as a numeric value (e.g. 0.33) or character (e.g. "1:3").

crop

Logical. Default TRUE. If TRUE, use the sf::st_crop() to trim results to area bounding box.

trim

Logical. Default FALSE. If TRUE, use the sf::st_intersection() function to trim results to area polygon.

crs

EPSG code for the coordinate reference system for the plot. Default is 2804. See https://epsg.io/ for more information.


elipousson/mapbaltimore documentation built on April 2, 2024, 4:23 p.m.