PRTools contents

PRTools manual

kcentres

KCENTRES

Finds K center objects from a distance matrix

   [LAB,J,DM] = KCENTRES(D,K,N)

Input
 D Distance matrix between, e.g. M objects (may be a dataset)
 K Number of center objects to be found (optional; default: 1)
 N Number of trials starting from a random initialization  (optional; default: 1)

Output
 LAB Integer labels: each object is assigned to its nearest center
 J Indices of the center objects
 DM A list of distances corresponding to J: for each center in J the maximum distance of the objects assigned to this center.

Description

Finds K center objects from a symmetric distance matrix D. The center  objects are chosen from all M objects such that the maximum of the  distances over all objects to the nearest center is minimized. For K > 1,  the results depend on a random initialization. The procedure is repeated  N times and the best result is returned.

If N = 0, initialisation is not random, but done by a systematic  selection based on a greedy approach.

See also

hclust, kmeans, emclust, modeseek,

PRTools contents

PRTools manual