Size variable in ggmap's get_googlemap no longer seems to work

ぃ、小莉子 提交于 2020-01-25 09:35:07

问题


The following function returns a plot of noise in the current version of ggmap (3.0.0):

library(ggmap)
register_google(key = "my_key")
ggmap(get_googlemap(size = c(620, 640)))

The plot appears correctly, however, when a square of any pixel dimensions is used (i.e., 640x640, 500x500, etc.). It's also worth noting that the URL returned by get_googlemap when using non-square dimensions is valid when pasted into the web browser, so the issue seems to be in how ggmap parses and plots the URL.

I've been plotting non-square maps with get_googlemap on a regular basis since last summer without any issues. I'm assuming I was using ggmap v2.6.1. I updated to 3.0.0 today, however, and now I'm getting the noisy plot as described.

来源:https://stackoverflow.com/questions/55908811/size-variable-in-ggmaps-get-googlemap-no-longer-seems-to-work

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!