computeKNNWeights-matrix-method: compute for each vector the weights to apply to it's K...

computeKNNWeights,matrix-methodR Documentation

compute for each vector the weights to apply to it's K nearest neighbors

Description

compute for each vector the weights to apply to it's K nearest neighbors

Usage

## S4 method for signature 'matrix'
computeKNNWeights(object, K = round(sqrt(nrow(object))))

Arguments

object

matrix to use for KNN

K

Number of neighbors to consider.

Value

a list of two items: indices: matrix, cells X neighbors Each row specifies indices of nearest neighbors weights: matrix, cells X neighbors Corresponding weights to nearest neighbors


YosefLab/VISION documentation built on June 14, 2024, 5:27 p.m.