Skip to content

Instantly share code, notes, and snippets.

@iUmarov
Created November 21, 2017 10:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save iUmarov/80551803b4cac86ad37ebeb787bf59a2 to your computer and use it in GitHub Desktop.
Save iUmarov/80551803b4cac86ad37ebeb787bf59a2 to your computer and use it in GitHub Desktop.
4 types of map view
#install.packages("ggmap")
#install.packages("gridExtra")
library(gridExtra)
library(ggmap)
map1 <- get_map("Tashkent", zoom = 11, maptype = "satellite", source = "google")
map2 <- get_map("Tashkent", zoom = 11, maptype = "roadmap", source = "google")
map3 <- get_map("Tashkent", zoom = 11, maptype = "terrain", source = "google")
map4 <- get_map("Tashkent", zoom = 11, maptype = "hybrid", source = "google")
plot1 <- ggmap(map1)
plot2 <- ggmap(map2)
plot3 <- ggmap(map3)
plot4 <- ggmap(map4)
grid.arrange(plot1, plot2, plot3, plot4, ncol= 2, nrow = 2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment