DATOS DE 2015

library(ggplot2)
library(ggmap)
register_google(apikey)

MAPAS DE CALI

qmap("Cali", zoom = 10)

qmap("Cali", zoom = 10, maptype = "hybrid")

qmap("Cali", zoom = 10, source = "stamen", maptype = "toner")

city <- get_map("Cali", zoom = 12)
str(city)
##  'ggmap' chr [1:1280, 1:1280] "#CED4C9" "#D3D8CE" "#D8DFD3" "#DCE2D6" ...
##  - attr(*, "source")= chr "google"
##  - attr(*, "maptype")= chr "terrain"
##  - attr(*, "zoom")= num 12
##  - attr(*, "bb")= tibble [1 x 4] (S3: tbl_df/tbl/data.frame)
##   ..$ ll.lat: num 3.34
##   ..$ ll.lon: num -76.6
##   ..$ ur.lat: num 3.56
##   ..$ ur.lon: num -76.4

PARADAS DEL MIO EN CALI

MioStops <- read.delim(file="D:/DOCUMENTOS FRANCISCO/Esp. Analitica Aplicada a los Negocios/2do Semestre/Comunicacion de los Analisis/Clase 1/Actividad RStudio/Data/MIO_STOPS.txt")
caliMap <- ggmap(city)
caliMap <- caliMap + geom_point(aes(x= DECIMALLONGITUDE, y = DECIMALLATITUDE),data = MioStops, color = "blue", alpha = 0.3)
caliMap

ZOOM AL MAPA DE MI CASA

  CaliCoords <- geocode("Caney,Cali")
  cityCenter <- get_map(c(CaliCoords$lon, CaliCoords$lat), source= "stamen", maptype="toner", zoom = 16)
  caliCenter <- ggmap(cityCenter)
  caliCenter <- caliCenter + geom_point(aes(x= DECIMALLONGITUDE, y = DECIMALLATITUDE),data = MioStops, color = "blue")
  caliCenter