get_osm: Download OSM data from geofabrik

Description Usage Arguments Value Note Examples

View source: R/get_osm.R

Description

get_osm download osm data from geofabrik. Instead of other services, this function relies only on direct links. Just that.

Usage

1
get_osm(region, type = "shp", file = tempfile(), quiet = FALSE)

Arguments

region

Region of interest, see urlgeo

type

"pbf", "shp" or "osm"

file

a character string (or vector, see url) with the name where the downloaded file is saved.

quiet

If TRUE, suppress status messages (if any), and the progress bar.

Value

Download a file

Note

all regions were transformed with iconv to "ASCII//TRANSLIT"

Examples

1
2
3
4
head(urlgeo)
get_osm("Sao Tome and Principe")
get_osm("Sao Tome and Principe", "pbf")
get_osm("Sao Tome and Principe", "osm")

geofabrik documentation built on Aug. 26, 2020, 5:12 p.m.