de.aitools.dm.clustering.dendrogram
Class DendrogramBase<S extends ClusterStep>

java.lang.Object
  extended by de.aitools.dm.clustering.dendrogram.DendrogramBase<S>
All Implemented Interfaces:
Dendrogram<S>, java.lang.Iterable<DendrogramIterator<S>>

public abstract class DendrogramBase<S extends ClusterStep>
extends java.lang.Object
implements Dendrogram<S>

A basic implementation for a Dendrogram. An implementation only needs to fill the list of ClusterSteps using add(ClusterStep) and implement Dendrogram.iterator().

Version:
$Id: DendrogramBase.java,v 1.1 2011/06/22 14:22:51 dogu3912 Exp $
Author:
johannes.kiesel(/\t)uni-weimar.de

Method Summary
 void add(S step)
          Add a ClusterStep to the back of the list.
 int numPoints()
           
 int numSteps()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface de.aitools.dm.clustering.dendrogram.Dendrogram
iterator
 

Method Detail

numSteps

public final int numSteps()
Specified by:
numSteps in interface Dendrogram<S extends ClusterStep>
Returns:
Number of different ClusterSteps this dendrogram knows of.

numPoints

public final int numPoints()
Specified by:
numPoints in interface Dendrogram<S extends ClusterStep>
Returns:
Number of input points that were clustered.

add

public final void add(S step)
Add a ClusterStep to the back of the list.

Parameters:
step - The step to be added.