public class MOA
extends weka.datagenerators.ClassificationGenerator
-h Prints this help.
-o <file> The name of the output file, otherwise the generated data is printed to stdout.
-r <name> The name of the relation.
-d Whether to print debug informations.
-S The seed for random function (default 1)
-n <num> The number of examples to generate (default 100)
-B <classname + options> The MOA stream generator. (default: moa.streams.generators.LEDGenerator)
Modifier and Type | Field and Description |
---|---|
protected SamoaToWekaInstanceConverter |
instanceConverter |
protected InstanceStream |
m_ActualGenerator
the actual data generator.
|
protected ClassOption |
m_Generator
for manipulating the generator through the GUI.
|
Constructor and Description |
---|
MOA() |
Modifier and Type | Method and Description |
---|---|
weka.core.Instances |
defineDataFormat()
Initializes the format for the dataset produced.
|
weka.core.Instance |
generateExample()
Generates one example of the dataset.
|
weka.core.Instances |
generateExamples()
Generates all examples of the dataset.
|
String |
generateFinished()
Generates a comment string that documentats the data generator.
|
String |
generateStart()
Generates a comment string that documentates the data generator.
|
String |
generatorTipText()
Returns the tooltip displayed in the GUI.
|
ClassOption |
getGenerator()
Returns the current MOA stream generator in use.
|
String[] |
getOptions()
Gets the current settings of the datagenerator.
|
String |
getRevision()
Returns the revision string.
|
boolean |
getSingleModeFlag()
Return if single mode is set for the given data generator
mode depends on option setting and or generator type.
|
String |
globalInfo()
Returns a string describing this data generator.
|
Enumeration |
listOptions()
Returns an enumeration describing the available options.
|
static void |
main(String[] args)
Main method for executing this class.
|
void |
setGenerator(ClassOption value)
Sets the MOA stream generator to use.
|
void |
setOptions(String[] options)
Parses a list of options for this object.
|
defaultNumExamples, getNumExamples, numExamplesTipText, setNumExamples
addToBlacklist, clearBlacklist, debugTipText, defaultNumExamplesAct, defaultOutput, defaultRelationName, defaultSeed, enumToVector, formatTipText, getDatasetFormat, getDebug, getEpilogue, getNumExamplesAct, getOutput, getPrologue, getRandom, getRelationName, getRelationNameToUse, getSeed, isOnBlacklist, makeData, makeOptionString, numExamplesActTipText, outputTipText, randomTipText, relationNameTipText, removeBlacklist, runDataGenerator, seedTipText, setDatasetFormat, setDebug, setNumExamplesAct, setOutput, setRandom, setRelationName, setSeed, toStringFormat
protected InstanceStream m_ActualGenerator
protected ClassOption m_Generator
protected SamoaToWekaInstanceConverter instanceConverter
public String globalInfo()
public Enumeration listOptions()
listOptions
in interface weka.core.OptionHandler
listOptions
in class weka.datagenerators.ClassificationGenerator
public void setOptions(String[] options) throws Exception
-h Prints this help.
-o <file> The name of the output file, otherwise the generated data is printed to stdout.
-r <name> The name of the relation.
-d Whether to print debug informations.
-S The seed for random function (default 1)
-n <num> The number of examples to generate (default 100)
-B <classname + options> The MOA stream generator. (default: moa.streams.generators.LEDGenerator)
setOptions
in interface weka.core.OptionHandler
setOptions
in class weka.datagenerators.ClassificationGenerator
options
- the list of options as an array of stringsException
- if an option is not supportedpublic String[] getOptions()
getOptions
in interface weka.core.OptionHandler
getOptions
in class weka.datagenerators.ClassificationGenerator
public void setGenerator(ClassOption value)
value
- the stream generator to usepublic ClassOption getGenerator()
public String generatorTipText()
public boolean getSingleModeFlag() throws Exception
getSingleModeFlag
in class weka.datagenerators.DataGenerator
Exception
- if mode is not set yetpublic weka.core.Instances defineDataFormat() throws Exception
defineDataFormat
in class weka.datagenerators.DataGenerator
Exception
- if the generating of the format failedpublic weka.core.Instance generateExample() throws Exception
generateExample
in class weka.datagenerators.DataGenerator
Exception
- if the format of the dataset is not yet definedException
- if the generator only works with generateExamples
which means in non single modepublic weka.core.Instances generateExamples() throws Exception
public String generateStart()
generateStart
in class weka.datagenerators.DataGenerator
public String generateFinished() throws Exception
generateFinished
in class weka.datagenerators.DataGenerator
Exception
- if the generating of the documentaion failspublic String getRevision()
public static void main(String[] args)
args
- should contain arguments for the data producer:Copyright © 2019 University of Waikato, Hamilton, NZ. All Rights Reserved.