find_nn_k {lle}R Documentation

Find k nearest neighbours.

Description

Finds the nearest k points for every point of the input data.

Usage

 find_nn_k(X, k, iLLE = FALSE) 

Arguments

X

matrix object containing the input data.

k

number of neighbours.

iLLE

a logical values indicating wheater to use improved LLE. See lle.

Value

neighbours

matrix with N rows and columns. If x_j is a neighbour of x_i then neighbours[i,j] is one, else zero.

See Also

find_nn_eps

Examples

	data( lle_scurve_data )
	X <- lle_scurve_data
	neighbours <- find_nn_k( X, 5 )
	table( rowSums( neighbours ) )

[Package lle version 1.1 Index]