Description Usage Arguments Value Examples
View source: R/geocodeAddresses.R
Get the coordinates of many addresses using the Google Maps API.
1 2 3 | geocodeAddresses(addresses, prev.results = NULL, address.components = TRUE,
print.progress = TRUE, pause.time = 0.02,
progress.save.file = NULL)
|
addresses |
The address to search for as a character vector. These should be as clear as possible, i.e. "Street, City, State, Country" |
prev.results |
If bulk searching for many addresses, you may be cut off part of the way through. By providing the output of a previous call of this function, the already-found locations will be skipped. |
address.components |
Whether or not the addresses of the found locations
should be included in the results (useful for checking accuracy). If
|
print.progress |
Whether or not the progress of the function should be shown. |
pause.time |
Amount of time in seconds to wait after a request (if performing multiple requests in a loop). |
progress.save.file |
If a file name is provided, the function will save
the progress after each request. It saves as an |
Returns a data.frame
with the coordinates (and address components if
requested) for each location in addresses
.
1 2 | addresses <- c("Time Square, New York City", "24 Beacon St, Boston, MA")
geocodeAddresses(addresses)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.