knn_dist: K-Nearest Neighbors Distance Generic Function

View source: R/knn_c.R

knn_distR Documentation

K-Nearest Neighbors Distance Generic Function

Description

A generic function for computing distances between data points for k-nearest neighbors analysis.

Usage

knn_dist(x, y)

Arguments

x

The first argument for method dispatch. The type of this argument determines which method is called.

y

The second argument for method dispatch. The type of this argument determines which method is called.

Details

This function is a generic for computing k-nearest neighbors distances. Methods should be implemented for specific classes to define how distances are calculated.

Value

The return value depends on the method implemented for the specific classes of x and y.

See Also

knn_dist.default for the default method.


COHHIO/clarity.looker documentation built on Sept. 6, 2024, 1:47 a.m.