pointsPolylineD {SpatialGraph} | R Documentation |
closest points in a polyline to a set of points
Description
pointsPolylineD
returns a list with a number of components from a points to polyline analysis
Usage
pointsPolylineD(xy, xyp)
Arguments
xy |
n x 2 [x,y] matrix defining the polyline |
xyp |
p x 2 [x,y] matrix with a point set |
Details
pointsPolylineD
conducts a detailed points to polyline distance analysis. First the distance from the set of points to the lines defined by every single segment in the polyline is obtained by succesive calls to pointLineD
, then the distance to every single node in the polyline are also obtained. The lower distance is chosen.
Value
A data.frame
with the columns: inode
is the index of the first node in the closest segment to each point, x0
and y0
are the corresponding coordinates of those nodes, xc
and yc
are the coordinates of the point in the polyline closest to each point in xyp
, these may be but are not necessarily one the polyline nodes, dis
it the distance from each point tho the polyline, chain0
is the chainage of x0,y0
with the polyline, and dc
is the differential chainage from xc,yc
to x0,y0