ggmap
ggmap copied to clipboard
Map Type forced to Terrain when bbox provided to get_map()
Hi David!
Love using this package. However, I've found something odd with the version currently on CRAN.
In the code for get_map():
if (is.numeric(location) && length(location) == 4) {
location_type <- "bbox"
location_stop <- FALSE
source <- "stamen"
maptype <- "terrain"
# ... other code
}
It seems like if the location is specified by a bounding box then:
- the source is changed to Stamen (cool, this makes sense!) but
- the map type is forced to "terrain".
The second item doesn't really make sense. What about the other map types available from Stamen, like "terrain-lines"? Would it not be better to just check here whether the requested (or default) map type is valid for Stamen?
Thanks for considering this and also thanks for your work in maintaining this great package.
Best regards, Andrew.