New answers tagged

0 votes

Count points inside polygons using R

You could use lenghts() of st_intersects(gr, points_in_polygons). A generic example with 10x10 grid and sampled points might look like this: library(sf) #> Linking to GEOS 3.11.2, GDAL 3.6.2, PROJ ...
margusl's user avatar
  • 131

Top 50 recent answers are included