This script uses RCurl and RJSONIO to download data from Google's API to get the latitude, longitude, location type, and formatted address
library(RCurl)
library(RJSONIO)
library(plyr)
| #Write geojson | |
| #==== | |
| #Load libraries | |
| library(rgdal) | |
| #dataMap is a dataframe with coordinates on cols 11 (LATITUDE) and 12 (LONGITUDE) | |
| #Transfor coordinates to numeric | |
| dataMap$LATITUDE <- as.numeric(dataMap$LATITUDE) | |
| dataMap$LONGITUDE <- as.numeric(dataMap$LONGITUDE) |