I have a points layer within a buffer derived from a transect. I need to sample a specified number of points, and ideally systematically based on distance. I have calculated the distances from a common furthest point using the NNJoin plugin, the challenge is how to select the specified points, from the closest to the furthest. In addition, does it matter how many points are selected from each side of the transect?
1 Answer
Use QGIS expressions with Geometry generator (for visulaization only) or Geometry by expression (to create actual geomtries): see here for details about both options.
Use it with this expression - here for the 100 closest points to the line:
collect_geometries(
overlay_nearest (
'points',
$geometry,
limit:=100 -- change the no. of points here
)
)
Red: 1000 points; yellow: the 100 points closest to the line: