public class CobWeb extends AbstractClusterer
| Modifier and Type | Field and Description |
|---|---|
FloatOption |
acuityOption |
static String |
classifierPurposeString |
FloatOption |
cutoffOption |
protected double |
m_acuity
Acuity (minimum standard deviation).
|
protected moa.clusterers.CobWeb.CNode |
m_cobwebTree
Holds the root of the Cobweb tree.
|
protected double |
m_cutoff
Cutoff (minimum category utility).
|
protected static double |
m_normal
Normal constant.
|
protected int |
m_numberMerges
the number of merges that happened
|
protected int |
m_numberOfClusters
Number of clusters (nodes in the tree).
|
protected boolean |
m_numberOfClustersDetermined
whether the number of clusters was already determined
|
protected int |
m_numberSplits
the number of splits that happened
|
protected boolean |
m_saveInstances
Output instances in graph representation of Cobweb tree (Allows
instances at nodes in the tree to be visualized in the Explorer).
|
IntOption |
randomSeedOption |
clustererRandom, clustering, evaluateMicroClusteringOption, modelContext, randomSeed, trainingWeightSeenByModelclassOptionNamesToPreparedObjects, options| Constructor and Description |
|---|
CobWeb() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
determineNumberOfClusters()
determines the number of clusters if necessary
|
double |
getAcuity()
get the acuity value
|
Clustering |
getClusteringResult() |
double |
getCutoff()
get the cutoff
|
void |
getModelDescription(StringBuilder out,
int indent) |
protected Measurement[] |
getModelMeasurementsImpl() |
boolean |
getSaveInstanceData()
Get the value of saveInstances.
|
double[] |
getVotesForInstance(weka.core.Instance instance)
Classifies a given instance.
|
String |
graph()
Generates the graph string of the Cobweb tree
|
boolean |
isRandomizable() |
int |
numberOfClusters()
Returns the number of clusters.
|
void |
resetLearningImpl() |
void |
setAcuity(double a)
set the acuity.
|
void |
setCutoff(double c)
set the cutoff
|
void |
setSaveInstanceData(boolean newsaveInstances)
Set the value of saveInstances.
|
void |
trainOnInstanceImpl(weka.core.Instance newInstance)
Adds an instance to the clusterer.
|
contextIsCompatible, copy, getAttributeNameString, getAWTRenderer, getClassLabelString, getClassNameString, getDescription, getMicroClusteringResult, getModelContext, getModelMeasurements, getNominalValueString, getPurposeString, getSubClusterers, implementsMicroClusterer, keepClassLabel, modelAttIndexToInstanceAttIndex, modelAttIndexToInstanceAttIndex, prepareForUseImpl, resetLearning, setModelContext, setRandomSeed, trainingHasStarted, trainingWeightSeenByModel, trainOnInstancediscoverOptionsViaReflection, getCLICreationString, getOptions, getPreparedClassOption, getPreparedClassOption, prepareClassOptions, prepareForUse, prepareForUsecopy, measureByteSize, measureByteSize, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetCLICreationString, getOptions, prepareForUse, prepareForUsemeasureByteSizepublic FloatOption acuityOption
public FloatOption cutoffOption
public IntOption randomSeedOption
protected static final double m_normal
protected double m_acuity
protected double m_cutoff
protected moa.clusterers.CobWeb.CNode m_cobwebTree
protected int m_numberOfClusters
protected boolean m_numberOfClustersDetermined
protected int m_numberSplits
protected int m_numberMerges
protected boolean m_saveInstances
public static final String classifierPurposeString
public void resetLearningImpl()
resetLearningImpl in class AbstractClustererpublic void trainOnInstanceImpl(weka.core.Instance newInstance)
trainOnInstanceImpl in class AbstractClusterernewInstance - the instance to be addedException - if something goes wrongpublic double[] getVotesForInstance(weka.core.Instance instance)
instance - the instance to be assigned to a clusterException - if instance could not be classified
successfullyprotected void determineNumberOfClusters()
public int numberOfClusters()
protected Measurement[] getModelMeasurementsImpl()
getModelMeasurementsImpl in class AbstractClustererpublic void getModelDescription(StringBuilder out, int indent)
getModelDescription in class AbstractClustererpublic boolean isRandomizable()
public String graph()
String valueException - if an error occurspublic void setAcuity(double a)
a - the acuity valuepublic double getAcuity()
public void setCutoff(double c)
c - the cutofpublic double getCutoff()
public boolean getSaveInstanceData()
public void setSaveInstanceData(boolean newsaveInstances)
newsaveInstances - Value to assign to saveInstances.public Clustering getClusteringResult()
Copyright © 2014 University of Waikato, Hamilton, NZ. All Rights Reserved.