Skip to main content

Nearest

The feature nearest a point, with its distance in kilometers in distanceToPoint, as turf.nearestPoint.

Syntax​

{ "id": "n1", "op": "nearest", "name": "nearest", "x": 0, "y": 0, "params": {} }

An edge into it ends at "targetPort": "in"; one out of it starts at "sourcePort": "out"; a parameter is set in params (leave out the ones at their default), driven by an edge to par:lng, or read elsewhere as ch('nearest/lng').

Inputs​

PortTypeTakes
intableone edge

Parameters​

ParameterKindDefaultChoices
lngfloat0
latfloat0

Outputs​

PortType
outtable

Details​

Older projects​

Projects saved before documents used operator classes. These convert to nearest when they open: NearestPointOp.