Learn R Programming

hereR (version 0.9.1)

reverse_geocode: HERE Geocoding & Search API: Reverse Geocode

Description

Get addresses from locations using the HERE 'Geocoder' API. The return value is an sf object, containing point geometries with suggestions for addresses near the provided POIs.

Usage

reverse_geocode(poi, results = 1, sf = TRUE, url_only = FALSE)

Value

If sf = TRUE, an sf object, containing the position coordinates of the reverse geocoded POIs as geometry list column and the access coordinates as well-known text (WKT). If sf = FALSE, a data.frame containing the coordinates of the reverse geocoded POIs as lng, lat columns.

Arguments

poi

sf object, Points of Interest (POIs) of geometry type POINT.

results

numeric, maximum number of results (Valid range: 1 and 100).

sf

boolean, return an sf object (default = TRUE) or a data.frame?

url_only

boolean, only return the generated URLs (default = FALSE)?

References

HERE Geocoder API: Reverse Geocode

Examples

Run this code
# Provide an API Key for a HERE project
set_key("")

# Get addresses
addresses <- reverse_geocode(poi = poi, results = 3, url_only = TRUE)

Run the code above in your browser using DataLab