xor
Description
calculates the geometric exclusive OR of the specified point, line, or polygon shapes by
comparing the shapes in shapeout
= xor(shape1
,shape2
)shape1
to the shapes in
shape2
. The function calculates element-wise exclusive
ORs.
When you specify point shapes, the exclusive OR is a point shape that contains the points in
shape1
that are not inshape2
, and the points inshape2
that are not inshape1
.When you specify line shapes, the exclusive OR is a line shape that contains the line parts in
shape1
that are not inshape2
, and the line parts inshape2
that are not inshape1
.When you specify polygon shapes, the exclusive OR is a polygon shape that contains the polygon regions in
shape1
that are not inshape2
, and the polygon regions inshape2
that are not inshape1
.
Examples
Input Arguments
Output Arguments
Version History
Introduced in R2025a