find_ordered_nn_brute: Naive brute force nearest neighbor finder

Description Usage Arguments Value

View source: R/nearest_neighbor_functions.R

Description

Naive brute force nearest neighbor finder

Usage

1

Arguments

locs

matrix of locations

m

number of neighbors

Value

An matrix containing the indices of the neighbors. Row i of the returned matrix contains the indices of the nearest m locations to the i'th location. Indices are ordered within a row to be increasing in distance. By convention, we consider a location to neighbor itself, so the first entry of row i is i, the second entry is the index of the nearest location, and so on. Because each location neighbors itself, the returned matrix has m+1 columns.


GpGp documentation built on June 10, 2021, 1:07 a.m.