constrain random points with a polygon in R using sp library

المشرف العام

Administrator
طاقم الإدارة
I have a map of London's waterways, which I've grided into a raster dataset to enable me to measure proximity to water from randomly generated points.

What I'd like to do please is to constrain the randomly generated points to a polygon (which represents the sampling area) within the larger grid.


This is the code I've used:randLocs
 
أعلى