Calculate the distance between a pair of spatial boundaries

distance(x, y, measure, time = NULL)


x, y

Objects of the class slendr


How to measure distance? This can be either 'border' (distance between the borders of x and y) or 'center' (distance between their centroids).


Time closest to the spatial maps of x and y if they represent slendr_pop population boundaries (ignored for general slendr_region objects)


If the coordinate reference system was specified, a distance in projected units (i.e. meters) is returned. Otherwise the function returns a normal Euclidian distance.