adams.flow.transformer.wekaclusterer
Class ClusterCenters

java.lang.Object
  extended by adams.core.ConsoleObject
      extended by adams.core.option.AbstractOptionHandler
          extended by adams.flow.transformer.wekaclusterer.AbstractClustererPostProcessor
              extended by adams.flow.transformer.wekaclusterer.AbstractClusterMembershipPostProcessor
                  extended by adams.flow.transformer.wekaclusterer.ClusterCenters
All Implemented Interfaces:
AdditionalInformationHandler, Debuggable, Destroyable, OptionHandler, SizeOfHandler, Serializable

public class ClusterCenters
extends AbstractClusterMembershipPostProcessor

Computes the cluster centers for the provided dataset. An additional attribute is added to the dataset structure that contains the cluster index.
Only numeric attributes are considered when computing the centers.
Stored in container under: Clustered dataset

Valid options are:

-D <int> (property: debugLevel)
    The greater the number the more additional info the scheme may output to 
    the console (0 = off).
    default: 0
    minimum: 0
 

Version:
$Revision: 4995 $
Author:
fracpete (fracpete at waikato dot ac dot nz)
See Also:
Serialized Form

Field Summary
 
Fields inherited from class adams.flow.transformer.wekaclusterer.AbstractClusterMembershipPostProcessor
VALUE_CLUSTERED_DATASET
 
Fields inherited from class adams.core.option.AbstractOptionHandler
m_DebugLevel, m_OptionManager
 
Constructor Summary
ClusterCenters()
           
 
Method Summary
protected  weka.core.Instances calculateCenters(weka.core.Instances data, weka.clusterers.Clusterer clusterer, weka.core.Instances outputFormat)
          Calculates the centers
protected  weka.core.Instances createOutputFormat(weka.core.Instances data)
          Generates the output format (additional attribute for cluster index).
 String globalInfo()
          Returns a string describing the object.
protected  weka.core.Instances processDatasetWithClusterer(weka.core.Instances data, weka.clusterers.Clusterer clusterer)
          Performs some form of processing on the full dataset.
 
Methods inherited from class adams.flow.transformer.wekaclusterer.AbstractClusterMembershipPostProcessor
check, doPostProcess, getContainerKeys
 
Methods inherited from class adams.flow.transformer.wekaclusterer.AbstractClustererPostProcessor
getAdditionalInformation, postProcess
 
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, debug, debug, debugLevelTipText, defineOptions, destroy, finishInit, getDebugLevel, getOptionManager, initialize, isDebugOn, newOptionManager, reset, setDebugLevel, toCommandLine, toString
 
Methods inherited from class adams.core.ConsoleObject
getDebugging, getSystemErr, getSystemOut, sizeOf
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClusterCenters

public ClusterCenters()
Method Detail

globalInfo

public String globalInfo()
Returns a string describing the object.

Specified by:
globalInfo in class AbstractOptionHandler
Returns:
a description suitable for displaying in the gui

createOutputFormat

protected weka.core.Instances createOutputFormat(weka.core.Instances data)
Generates the output format (additional attribute for cluster index).

Parameters:
data - the original input data
Returns:
the header of the output format

calculateCenters

protected weka.core.Instances calculateCenters(weka.core.Instances data,
                                               weka.clusterers.Clusterer clusterer,
                                               weka.core.Instances outputFormat)
Calculates the centers


processDatasetWithClusterer

protected weka.core.Instances processDatasetWithClusterer(weka.core.Instances data,
                                                          weka.clusterers.Clusterer clusterer)
Performs some form of processing on the full dataset.

Specified by:
processDatasetWithClusterer in class AbstractClusterMembershipPostProcessor


Copyright © 2012 University of Waikato, Hamilton, NZ. All Rights Reserved.