How to prevent ggmap (with Stamen maps) from misal

2019-05-18 08:31发布

When using ggmap, Stamen maps and continental-level zooms (zoom=3), the point-latitudes do not align with the map. For example:

library(ggmap)
gc <- geocode('the white house')

qmap('the white house', zoom = 3) + # looks good
  geom_point(aes(x = lon, y = lat), data = gc, colour = 'red')

qmap('the white house', zoom = 3, source = 'stamen', maptype="toner") + # not so good
  geom_point(aes(x = lon, y = lat), data = gc, colour = 'red')

This seems to have been and addressed defect for googlemaps and osm maps - what strategies can I employ to work-around for Stamen?

标签: r ggplot2 ggmap
0条回答
登录 后发表回答