I have a list of neighborhood names from Rio de Janeiro and would like to get the latitude and longitudes associated with name.
When I type any of the names into Google, it responds with a lat/long tuple as seen below.
I'm wondering if there's a programmatic way to do this, as opposed to going through, Googling each neighborhood name, and typing the lat/long for the neighborhood. I suspect there may be a way to do this with ggmap
but any guidance would be most appreciated.
library(ggmap)
geocode("copacabana")
# Information from URL : http://maps.googleapis.com/maps/api/geocode/json?address=copacabana&sensor=false
# lon lat
# 1 -79.38823 43.64842