How to intersect lines and polygons in R?

المشرف العام

Administrator
طاقم الإدارة
Following on from an answer about intersecting polygons with lines to chop up a polygon into smaller polygon units (in QGIS), I wanted to try the same thing in R. However, I cannot seem to find a method that works!

over() doesn't have a method for polygons intersecting with lines; I found gIntersection() from rgeos but it fails:

require(sp)require(rgeos)poly
 
أعلى