Package weka.clusterers
Class SingleClustererEnhancer
- java.lang.Object
-
- weka.clusterers.AbstractClusterer
-
- weka.clusterers.SingleClustererEnhancer
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Cloneable
,Clusterer
,CapabilitiesHandler
,OptionHandler
,RevisionHandler
- Direct Known Subclasses:
FilteredClusterer
public abstract class SingleClustererEnhancer extends AbstractClusterer implements OptionHandler
Meta-clusterer for enhancing a base clusterer.- Version:
- $Revision: 1.4 $
- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SingleClustererEnhancer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
clustererTipText()
Returns the tip text for this propertyCapabilities
getCapabilities()
Returns default capabilities of the clusterer.Clusterer
getClusterer()
Get the clusterer used as the base clusterer.java.lang.String[]
getOptions()
Gets the current settings of the clusterer.java.util.Enumeration
listOptions()
Returns an enumeration describing the available options.int
numberOfClusters()
Returns the number of clusters.void
setClusterer(Clusterer value)
Set the base clusterer.void
setOptions(java.lang.String[] options)
Parses a given list of options.-
Methods inherited from class weka.clusterers.AbstractClusterer
buildClusterer, clusterInstance, distributionForInstance, forName, getRevision, makeCopies, makeCopy
-
-
-
-
Method Detail
-
listOptions
public java.util.Enumeration listOptions()
Returns an enumeration describing the available options.- Specified by:
listOptions
in interfaceOptionHandler
- Returns:
- an enumeration of all the available options.
-
setOptions
public void setOptions(java.lang.String[] options) throws java.lang.Exception
Parses a given list of options.- Specified by:
setOptions
in interfaceOptionHandler
- Parameters:
options
- the list of options as an array of strings- Throws:
java.lang.Exception
- if an option is not supported
-
getOptions
public java.lang.String[] getOptions()
Gets the current settings of the clusterer.- Specified by:
getOptions
in interfaceOptionHandler
- Returns:
- an array of strings suitable for passing to setOptions
-
clustererTipText
public java.lang.String clustererTipText()
Returns the tip text for this property- Returns:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setClusterer
public void setClusterer(Clusterer value)
Set the base clusterer.- Parameters:
value
- the classifier to use.
-
getClusterer
public Clusterer getClusterer()
Get the clusterer used as the base clusterer.- Returns:
- the base clusterer
-
getCapabilities
public Capabilities getCapabilities()
Returns default capabilities of the clusterer.- Specified by:
getCapabilities
in interfaceCapabilitiesHandler
- Specified by:
getCapabilities
in interfaceClusterer
- Overrides:
getCapabilities
in classAbstractClusterer
- Returns:
- the capabilities of this clusterer
- See Also:
Capabilities
-
numberOfClusters
public int numberOfClusters() throws java.lang.Exception
Returns the number of clusters.- Specified by:
numberOfClusters
in interfaceClusterer
- Specified by:
numberOfClusters
in classAbstractClusterer
- Returns:
- the number of clusters generated for a training dataset.
- Throws:
java.lang.Exception
- if number of clusters could not be returned successfully
-
-