User 'rusers.sh' asks a question about the library 'spatstat':

> intersect.owin() works for intersection.
> Say polygon B located inside A. Is there any function in R for us to
> get the complement part of  B in  polygon A?

See complement.owin.
Try
       Bcom <- complement.owin(B, frame=bounding.box(A))
       AminB <- intersect.owin(A, Bcom)

If you want the answer to be a polygon, you'll need to set spatstat.options(gpclib=TRUE), unless A is a rectangle.

Adrian Baddeley

_______________________________________________
R-sig-Geo mailing list
R-sig-Geo@stat.math.ethz.ch
https://stat.ethz.ch/mailman/listinfo/r-sig-geo

Reply via email to