point.in.polygon.Rd
verifies for one or more points whether they fall in a given polygon
point.in.polygon(point.x, point.y, pol.x, pol.y, mode.checked=FALSE)
point.x | numerical array of x-coordinates of points |
---|---|
point.y | numerical array of y-coordinates of points |
pol.x | numerical array of x-coordinates of polygon |
pol.y | numerical array of y-coordinates of polygon |
mode.checked | default FALSE, used internally to save time when all the other argument are known to be of storage mode double |
integer array; values are: 0: point is strictly exterior to pol; 1: point is strictly interior to pol; 2: point lies on the relative interior of an edge of pol; 3: point is a vertex of pol.
Uses the C function InPoly(). InPoly is Copyright (c) 1998 by Joseph O'Rourke. It may be freely redistributed in its entirety provided that this copyright notice is not removed.
#> [1] 0 0 3 1 3 0 0 0 0 0#> [1] 0 0 2 1 2 0 0 0 0 0