|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectadams.core.ConsoleObject
adams.core.option.AbstractOptionHandler
adams.data.instances.AbstractInstanceGenerator<Heatmap>
adams.data.instances.AbstractFieldInstanceGenerator
adams.data.instances.HistogramInstanceGenerator
public class HistogramInstanceGenerator
A generator for turning a heatmap and fields of its report into weka.core.Instance objects.
Zero values are omitted.
-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
-add-db-id (property: addDatabaseID) If set to true, then the database ID will be added to the output.
-add-site-id (property: addSiteID) If set to true, then the site ID will be added to the output.
-add-herd-number (property: addHerdNumber) If set to true, then the herd number will be added to the output.
-add-cow-number (property: addCowNumber) If set to true, then the cow number will be added to the output.
-field <adams.data.report.Field> [-field ...] (property: fields) The fields to add to the output. default:
-min-intensity <double> (property: minIntensity) The minimum intensity to keep. default: -1.0 minimum: -1.0
-max-intensity <double> (property: maxIntensity) The maximum intensity to keep. default: -1.0 minimum: -1.0
-num-bins <int> (property: numBins) The number of bins to use for the histogram. default: 100
-only-indicators (property: onlyIndicators) Whether to output only indicator attributes instead of counts.
| Field Summary | |
|---|---|
protected double |
m_MaxIntensity
the maximum intensity to keep. |
protected double |
m_MinIntensity
the minimum intensity to keep. |
protected int |
m_NumBins
the number of bins to generate. |
protected boolean |
m_OnlyIndicators
whether to generate only indicator attributes. |
static String |
PREFIX_BIN
the prefix for the bins. |
| Fields inherited from class adams.data.instances.AbstractFieldInstanceGenerator |
|---|
m_Fields |
| Fields inherited from class adams.data.instances.AbstractInstanceGenerator |
|---|
LABEL_FALSE, LABEL_TRUE, m_AddDatabaseID, m_DatabaseConnection, m_OutputHeader, m_TolerateHeaderChanges |
| Fields inherited from class adams.core.option.AbstractOptionHandler |
|---|
m_DebugLevel, m_OptionManager |
| Constructor Summary | |
|---|---|
HistogramInstanceGenerator()
|
|
| Method Summary | |
|---|---|
protected void |
checkHeader(Heatmap data)
Checks whether the number of waves are the same. |
void |
defineOptions()
Adds options to the internal list of options. |
protected void |
generateHeader(Heatmap data)
Generates the header of the output data. |
protected Instance |
generateOutput(Heatmap data)
Generates the actual data. |
double |
getMaxIntensity()
Returns the maximum intensity to keep. |
double |
getMinIntensity()
Returns the minimum intensity to keep. |
int |
getNumBins()
Returns the number of bins to use. |
boolean |
getOnlyIndicators()
Returns whether only indicator attributes are output instead of counts. |
String |
globalInfo()
Returns a string describing the object. |
String |
maxIntensityTipText()
Returns the tip text for this property. |
String |
minIntensityTipText()
Returns the tip text for this property. |
String |
numBinsTipText()
Returns the tip text for this property. |
String |
onlyIndicatorsTipText()
Returns the tip text for this property. |
void |
setMaxIntensity(double value)
Sets the maximum intensity to keep. |
void |
setMinIntensity(double value)
Sets the minimum intensity to keep. |
void |
setNumBins(int value)
Sets the number of bins to use. |
void |
setOnlyIndicators(boolean value)
Sets whether only indicator attributes are output instead of counts. |
| Methods inherited from class adams.data.instances.AbstractFieldInstanceGenerator |
|---|
addFields, createAttribute, fieldsTipText, getDefaultDatabaseConnection, getFields, setFields |
| Methods inherited from class adams.data.instances.AbstractInstanceGenerator |
|---|
addDatabaseIDTipText, checkInput, checkSetup, cleanUp, compareTo, destroy, equals, forCommandLine, forName, generate, getAddDatabaseID, getDatabaseConnection, getGenerators, getOutputHeader, getTolerateHeaderChanges, initialize, interpretePosition, postProcessHeader, postProcessOutput, reset, setAddDatabaseID, setDatabaseConnection, setTolerateHeaderChanges, shallowCopy, shallowCopy, tolerateHeaderChangesTipText |
| Methods inherited from class adams.core.option.AbstractOptionHandler |
|---|
cleanUpOptions, debug, debug, debugLevelTipText, finishInit, getDebugLevel, getOptionManager, isDebugOn, newOptionManager, setDebugLevel, toCommandLine, toString |
| Methods inherited from class adams.core.ConsoleObject |
|---|
getDebugging, getSystemErr, getSystemOut, sizeOf |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final String PREFIX_BIN
protected double m_MinIntensity
protected double m_MaxIntensity
protected int m_NumBins
protected boolean m_OnlyIndicators
| Constructor Detail |
|---|
public HistogramInstanceGenerator()
| Method Detail |
|---|
public String globalInfo()
globalInfo in class AbstractOptionHandlerpublic void defineOptions()
defineOptions in interface OptionHandlerdefineOptions in class AbstractFieldInstanceGeneratorpublic void setMinIntensity(double value)
value - the intensitypublic double getMinIntensity()
public String minIntensityTipText()
public void setMaxIntensity(double value)
value - the intensitypublic double getMaxIntensity()
public String maxIntensityTipText()
public void setNumBins(int value)
value - the number of binspublic int getNumBins()
public String numBinsTipText()
public void setOnlyIndicators(boolean value)
value - if true then only indicator attributes are outputpublic boolean getOnlyIndicators()
public String onlyIndicatorsTipText()
protected void checkHeader(Heatmap data)
checkHeader in class AbstractFieldInstanceGeneratordata - the input dataprotected void generateHeader(Heatmap data)
generateHeader in class AbstractInstanceGenerator<Heatmap>data - the input dataprotected Instance generateOutput(Heatmap data)
generateOutput in class AbstractInstanceGenerator<Heatmap>data - the input data to transform
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||