stilt.flux.nearest_cell#

stilt.flux.nearest_cell(coords, values)[source]#

Index of the cell whose centre is nearest each value, or -1 outside.

Cells extend halfway to their neighbours; the outer cells extend by the same half spacing beyond the end centres.

Return type:

ndarray

Parameters: