Starting from a shapefile containing a fairly large number (about 20000) of potentially partially-overlapping polygons, I\'d need to extract all the sub-polygons originated by i
This has now been implemented in R package sf as the default result when st_intersection
is called with a single argument (sf or sfc), see https://r-spatial.github.io/sf/reference/geos_binary_ops.html for the examples. (I'm not sure the origins
field contains useful indexes; ideally they should point to indexes in x
only, right now they kind of self-refer).