How can I use Leaflet (in R) to smoothly pan/zoom from one point to another point?

Viewed 78

I am using flyTo() in leaflet (R), but I want to avoid how it zooms all the way out to world view before zooming in to the specified lat/lon. Is there a way to set the start point of the flyTo to certain bounds that have a higher zoom level than the world view? For example, I want the start point of the flyTo() to be at the level of a small city.

This is my current use of the function with no bound set:

%>% flyTo(
  lng = -122.17014,
  lat = 37.42752,
  zoom = 15
)
0 Answers
Related