Description Usage Arguments Value Note References Examples
Working function for synthesize_api()
. It will call
lower functions synthesize_google_api_geocode()
or
synthesize_google_api_revgeocode()
.
1 2 3 4 5 6 7 8 | synthesize_googlemap_api(url_body, api = c("geocode", "revgeocode"),
use_curl = TRUE, ...)
synthesize_google_api_geocode(url_body, region = NULL,
components = NULL, use_curl = TRUE, ...)
synthesize_google_api_revgeocode(url_body, result_type = NULL,
location_type = NULL, use_curl = TRUE, ...)
|
url_body |
character, the leading argument in the API URL. |
api |
character, 'geocode' or 'revgeocode'. |
use_curl |
logical, whether use |
... |
other arguments to pass to the function, e.g., |
region |
character, for geocoding. The region code, specified as a ccTLD ("top-level domain") two-character value. This parameter will only influence, not fully restrict, results from the geocoder. |
components |
character, for geocoding. A components filter with elements
separated by a pipe (|). The components filter is required if the request doesn't
include an address. Each element in the components filter consists of a
|
result_type |
character, for regeocoding. A filter of one or more address
types, separated by a pipe (|). If the parameter contains multiple address types,
the API returns all addresses that match any of the types. A note about
processing: The result_type parameter does not restrict the search to the
specified address type(s). Rather, the result_type acts as a post-search
filter: the API fetches all results for the specified latlng, then discards
those results that do not match the specified address type(s). Note:
This parameter is available only for requests that include an API key or
a client ID. The following values are supported: |
location_type |
character, for revgeocoding. A filter of one or more
location types, separated by a pipe (|). If the parameter contains multiple
location types, the API returns all addresses that match any of the types.
A note about processing: The location_type parameter does not restrict the
search to the specified location type(s). Rather, the location_type acts as
a post-search filter: the API fetches all results for the specified latlng,
then discards those results that do not match the specified location type(s).
Note: This parameter is available only for requests that include an API key
or a client ID. The following values are supported: |
A url
object for get_api_data()
use.
When key
is omitted or set NULL, the function will search for it
in the cache. If nothing is found, a GUI wizard will be launched for you to
input the API key. If you want to bypass API key, set key
= NA.
Googlemaps API documentation: https://developers.google.com/maps/documentation
1 2 3 4 | ## Not run:
synthesize_googlemap_api("<Address>", key="<YOUR GOOGLEMAP KEY>")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.