sn_create_city_boundary_id_combo: Create a city/id combination for proper caching

View source: R/sn_get.R

sn_create_city_boundary_id_comboR Documentation

Create a city/id combination for proper caching

Description

Create a city/id combination for proper caching

Usage

sn_create_city_boundary_id_combo(
  id,
  type,
  city = NULL,
  country = NULL,
  cache = TRUE
)

Arguments

id

A numeric vector of length 1, must correspond to the id of a boundary object on OpenStreetMap.

type

One of either "way", "relation", or "node".

city

The name of a city/municipality.

country

The name of the country. Requested to ensure correct identification of city.

cache

Logical, defaults to TRUE. If TRUE, stores data in local subfolder data/cities/country_name/city_name.rds

Value

A list, typically to be fed into 'get_boundary_by_id()“

Examples


create_city_boundary_id_combo(id = 45422208, type = "way", city = "Arad", country = "Romania")

# https://www.openstreetmap.org/relation/46663
create_city_boundary_id_combo(id = 46663, type = "relation", city = "Trento", country = "Italy", )

giocomai/streetnamer documentation built on Oct. 14, 2023, 6:27 p.m.