This function returns the shortest path between locations
in, or near to, segements on a SpatialLinesNetwork
.
route_local(sln, from, to, l = NULL)
sln  The SpatialLinesNetwork to use. 

from  Text string or coordinates (a numeric vector of

to  Text string or coordinates (a numeric vector of

l  Only needed if from and to are empty, in which case this should be a spatial object representing desire lines 
Other routes:
line2routeRetry()
,
line2route()
,
route_cyclestreets()
,
route_dodgr()
,
route_graphhopper()
,
route_transportapi_public()
,
route()
from < c(1.535181, 53.82534) to < c(1.52446, 53.80949) sln < SpatialLinesNetwork(route_network_sf) r < route_local(sln, from, to) plot(sln)r2 < route_local(sln = sln, cents_sf[3, ], cents_sf[4, ]) plot(r2$geometry, add = TRUE, col = "blue", lwd = 3)