Spatial Match Behavior
The behavior of the Spatial Match tool depends on the intersection method selected (Intersects, Contains or Within) and the types of the objects being tested. The tables below list the various combinations.
Intersects
Contains & Within
if... |
||
---|---|---|
Polygon |
Polygon |
99.99% of the second polygons area lies inside the first polygon. |
Polygon |
Line |
99.99% of the length of the line lies inside the polygon. |
Polygon |
Point |
the point is inside the polygon |
Polygon |
MultiPoint |
all the points are in the polygon. |
Line |
Polygon |
Never. |
Line |
Line |
Every segment (i.e. 2-point series) in the contained line also appears in the containing line. Segments consisting of the same 2 points in the opposite order (i.e. coded in the opposite direction) will still match. Lines that follow the same route geometrically may still not match if one uses more (unnecessary) points. |
Line |
Point |
the point is a vertex of the line. A line may cross over a point geometrically without a vertex, and the line will not be counted as containing the point. |
Line |
MultiPoint |
all the points are vertexes of the line. |
MultiPoint |
MultiPoint |
all the universe points are in the target. |
MultiPoint |
Point |
one of the points are in the MultiPoint. |
MultiPoint |
Polygon or Line |
Never. |
Point |
Polygon |
Never. |
Point |
Line |
Never. |
Point | Point | The points are the same. |
Spatial index
If specifying a Calgary (cydb) file, be aware that the Calgary spatial index uses 5 decimal places of accuracy for compression and speed. The YXDB spatial index uses 6 decimal places. This adds an addition round off error of up to a maximum of 1.8 feet to Calgary indexes. In other words, it is possible that a point can be 1.8 feet inside of a polygon and be found as outside in Calgary.