Base class for cluster functors.
Each cluster functor employs a different method for stepwise merging clusters up to a given threshold, starting from the most elementary partition of data. Elements are represented by indices of a given distance matrix, which also should represent the order of input.
virtual void operator() 
( 
DistanceMatrix< float > & 
original_distance, 


std::vector< BinaryTreeNode > & 
cluster_tree, 


const float 
threshold = 1 

) 
 const 

pure virtual 
abstract for clustering the indices according to their respective element distances
 Parameters

original_distance  DistanceMatrix<float> containing the distances of the elements to be clustered, will be changed during clustering process, make sure to have a copy or be able to redo 
cluster_tree  vector< BinaryTreeNode >, represents the clustering, each node contains the next merged clusters (not element indices) and their distance, strict order is kept: left_child < right_child, 
threshold  float value, the minimal distance from which on cluster merging is considered unrealistic. By default set to 1, i.e. complete clustering until only one cluster remains 
original_distance
is considered mirrored at the main diagonal, so only entries up the main diagonal are used. The threshold
can be taken from the maximal distance of two elements considered related and adapted in a way corresponding to the employed clustering method. The results are represented by cluster_tree
, to get the actual clustering (with element indices) from a certain step of the clustering
 See also
 BinaryTreeNode , ClusterAnalyzer::cut
Implemented in SingleLinkage, CompleteLinkage, and AverageLinkage.