Given a spatial extent (for example cbind(c(0,0),c(10,10)),I want to see whether there is a part of a SpatialPolygons falls in this extent? How can I do this? Thank you very much!
Tell me more
×
Geographic Information Systems Stack Exchange is a question and answer site for
cartographers, geographers and GIS professionals. It's 100% free, no registration required.
|
|
Never use |
|||||||||||
|
|
Expanding on spacedman's suggestion, here is how you can get the intersection of two extents (NULL if not intersecting). 'sp' is a Spatial* object
But it may indeed be, as whuber points out, that the polygon is in fact not inside extent e. If you need to know that, do
For large problems, it may be efficient to do
|
||||
|
|