
Return an OSM Overpass query as a data.frame object.
Source:R/get-osmdata-df.R
osmdata_data_frame.Rd
Return an OSM Overpass query as a data.frame object.
Arguments
- q
An object of class
overpass_query
constructed with opq and add_osm_feature. May be be omitted, in which case the attributes of the data.frame will not include the query.- doc
If missing,
doc
is obtained by issuing the overpass query,q
, otherwise either the name of a file from which to read data, or an object of class xml2 returned from osmdata_xml.- quiet
suppress status messages.
- stringsAsFactors
Should character strings in the 'data.frame' be coerced to factors?
Details
If you are not interested in the geometries of the results, it's a
good option to query for objects that match the features only and forget
about members of the ways and relations. You can achieve this by passing
the parameter body = "tags"
to opq
.
See also
Other extract:
osmdata_sc()
,
osmdata_sf()
,
osmdata_sp()
,
osmdata_xml()