Distance matrix of a set of points, or between two sets of points
1.1
distm(x, y, fun=distGeo)
Arguments
x: longitude/latitude of point(s). Can be a vector of two numbers, a matrix of 2 columns (first one is longitude, second is latitude) or a SpatialPoints* object
y: Same as x. If missing, y is the same as x
fun: A function to compute distances (e.g., distCosine or distGeo)