public abstract class ClusterGenerator extends DataGenerator
public static void main(String[] args) {
try {
DataGenerator.makeData(new RandomGenerator(), args);
}
catch (Exception e) {
e.printStackTrace();
System.err.println(e.getMessage());
}
}
| Modifier and Type | Field and Description |
|---|---|
protected Range |
m_booleanCols
Stores which columns are boolean (default numeric)
|
protected boolean |
m_ClassFlag
class flag
|
protected Range |
m_nominalCols
Stores which columns are nominal (default numeric)
|
protected int |
m_NumAttributes
Number of attribute the dataset should have
|
m_CreatingRelationName, m_DatasetFormat, m_Debug, m_DefaultOutput, m_NumExamplesAct, m_OptionBlacklist, m_Output, m_Random, m_RelationName, m_Seed| Constructor and Description |
|---|
ClusterGenerator()
initializes the generator
|
| Modifier and Type | Method and Description |
|---|---|
String |
booleanColsTipText()
Returns the tip text for this property
|
protected String |
checkIndices()
check if attribute types are not contradicting
|
String |
classFlagTipText()
Returns the tip text for this property
|
protected int |
defaultNumAttributes()
returns the default number of attributes
|
Range |
getBooleanCols()
returns the range of boolean attributes.
|
boolean |
getClassFlag()
Gets the class flag.
|
Range |
getNominalCols()
returns the range of nominal attributes
|
int |
getNumAttributes()
Gets the number of attributes that should be produced.
|
String[] |
getOptions()
Gets the current settings of the classifier.
|
Enumeration |
listOptions()
Returns an enumeration describing the available options.
|
String |
nominalColsTipText()
Returns the tip text for this property
|
String |
numAttributesTipText()
Returns the tip text for this property
|
void |
setBooleanCols(Range value)
Sets which attributes are boolean.
|
void |
setBooleanIndices(String rangeList)
Sets which attributes are boolean
|
void |
setClassFlag(boolean classFlag)
Sets the class flag, if class flag is set,
the cluster is listed as class atrribute in an extra attribute.
|
void |
setNominalCols(Range value)
Sets which attributes are nominal.
|
void |
setNominalIndices(String rangeList)
Sets which attributes are nominal
|
void |
setNumAttributes(int numAttributes)
Sets the number of attributes the dataset should have.
|
void |
setOptions(String[] options)
Sets the options.
|
addToBlacklist, clearBlacklist, debugTipText, defaultNumExamplesAct, defaultOutput, defaultRelationName, defaultSeed, defineDataFormat, enumToVector, formatTipText, generateExample, generateExamples, generateFinished, generateStart, getDatasetFormat, getDebug, getNumExamplesAct, getOutput, getRandom, getRelationName, getRelationNameToUse, getSeed, getSingleModeFlag, isOnBlacklist, makeData, makeOptionString, numExamplesActTipText, outputTipText, randomTipText, relationNameTipText, removeBlacklist, runDataGenerator, seedTipText, setDatasetFormat, setDebug, setNumExamplesAct, setOutput, setRandom, setRelationName, setSeed, toStringFormatclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetRevisionprotected int m_NumAttributes
protected boolean m_ClassFlag
protected Range m_booleanCols
protected Range m_nominalCols
public Enumeration listOptions()
listOptions in interface OptionHandlerlistOptions in class DataGeneratorpublic void setOptions(String[] options) throws Exception
setOptions in interface OptionHandlersetOptions in class DataGeneratoroptions - the optionsException - if invalid optionpublic String[] getOptions()
getOptions in interface OptionHandlergetOptions in class DataGeneratorDataGenerator.removeBlacklist(String[])protected int defaultNumAttributes()
public void setNumAttributes(int numAttributes)
numAttributes - the new number of attributespublic int getNumAttributes()
public String numAttributesTipText()
public void setClassFlag(boolean classFlag)
classFlag - the new class flagpublic boolean getClassFlag()
public String classFlagTipText()
public void setBooleanIndices(String rangeList)
rangeList - a string representing the list of attributes. Since
the string will typically come from a user, attributes are indexed from
1. IllegalArgumentException - if an invalid range list is suppliedpublic void setBooleanCols(Range value)
value - the range to usepublic Range getBooleanCols()
public String booleanColsTipText()
public void setNominalIndices(String rangeList)
rangeList - a string representing the list of attributes. Since
the string will typically come from a user, attributes are indexed from
1. IllegalArgumentException - if an invalid range list is suppliedpublic void setNominalCols(Range value)
value - the range to usepublic Range getNominalCols()
public String nominalColsTipText()
protected String checkIndices()
Copyright © 2015 University of Waikato, Hamilton, NZ. All rights reserved.