ClusterTools Contents

ClusterTools User Guide

clustinds

CLUSTINDS

Find object indices in cluster

    [IND,FIRST,LAST,LABC] = CLUSTINDS(LAB)

Input
 LAB Column vector with N cluster labels. In total C clusters

Output
 IND Column vector with N indices ranging from 1 to N.
 FIRST Column vector with C start points in IND of a cluster.
 LAST Column vector with C end points in IND of a cluster
 LAST(I) = FIRST(I+1)-1, LAST(END) = N.
 LABC Column vector with the C cluster labels.

Description

In case cluster labels in LAB are not sorted this routine is useful to  group them. Cluster K can be found by LAB(IND(FIRST(K):LAST(K))). Its  original label in LAB is LABC(K).

ClusterTools Contents

ClusterTools User Guide

This file has been automatically generated. If badly readable, use the help-command in Matlab.