Plugin icon

Nearest with greater value

Plugin ID: 2769

Get name (or ID) of and distance to the nearest feature with greater value in a certain field of a point layer.
Returns point layer with added attributes and a line layer with connecting lines.

(1) votes 
 Download latest

For each feature on a vector layer, get name (or ID) of and distance to the nearest neighbour with greater value in a certain field. On line or polygon layers, distance is calculated between the center points of the bounding boxes. Since version 2.0, distance is calculated on the WGS84 ellipsoid (not on the layer plane) by default.
The main output is a layer with added attributes neargtdist (distance), neargtdelta (difference in value), neargtname (name or ID), neargtcount. Note that the features are sorted from lowest to greatest value of the field that was used to compare values.
The field neargtcount gives the value of incoming connecting lines linking to points with smaller value.
Also returns a lines layer with connecting lines, as well as basic statistics of the distances and deltas (min, max, mean, quantiles).
Use cases: Which is the next larger city? How far is the next higher building? Which is the closest peak with higher elevation?
Useful for spatial analysis or to categorize features in order to apply different styles (e.g. major and minor summits).

2.0
0.3
Version QGIS >= QGIS <= Date
2.0 - 3.18.0 3.99.0 1530 riannek 2023-02-03T22:19:42.598685+00:00
1.1 - 3.18.0 3.99.0 251 riannek 2023-01-17T10:15:41.872285+00:00
1.0 - 3.0.0 3.99.0 574 riannek 2022-10-19T06:10:03.578884+00:00
0.3 3.0.0 3.99.0 406 riannek 2022-09-12T12:33:29.424040+00:00
0.1 3.0.0 3.99.0 181 riannek 2022-09-09T14:36:04.874333+00:00

QGIS sustaining members

Flagship membership


Flagship membership


Large membership


Large membership


Large membership


Large membership


Large membership


Large membership


Large membership


Large membership