R/resolve.R
dc_get_dcid_by_coordinates.Rd
Resolves geographic coordinates (provided as latitude and longitude) to Data Commons DCIDs using the geoCoordinate property.
dc_get_dcid_by_coordinates(
latitude,
longitude,
api_key = Sys.getenv("DATACOMMONS_API_KEY"),
base_url = Sys.getenv("DATACOMMONS_BASE_URL", unset =
"https://api.datacommons.org/v2/"),
return_type = "json"
)
A numeric vector of latitude values.
A numeric vector of longitude values.
Your Data Commons API key. If not provided, uses the
environment variable DATACOMMONS_API_KEY
.
The base URL of the Data Commons API. Defaults to the public
endpoint. For custom deployments, must end with /core/api/v2/
.
Return format: either "list"
(parsed R object) or
"json"
(JSON string).
A list or JSON string, depending on return_type
.