Package weka.classifiers.meta
Class HighLowSplitSingleClassifier
- java.lang.Object
-
- weka.classifiers.AbstractClassifier
-
- weka.classifiers.SingleClassifierEnhancer
-
- weka.classifiers.meta.HighLowSplitSingleClassifier
-
- All Implemented Interfaces:
Serializable,Cloneable,weka.classifiers.Classifier,weka.core.BatchPredictor,weka.core.CapabilitiesHandler,weka.core.CapabilitiesIgnorer,weka.core.CommandlineRunnable,weka.core.OptionHandler,weka.core.RevisionHandler,weka.core.WeightedInstancesHandler
public class HighLowSplitSingleClassifier extends weka.classifiers.SingleClassifierEnhancer implements weka.core.WeightedInstancesHandlerUses base classifier to get guess, then get prediction from either lo/hi classifier
Valid options are:
-W Full name of base classifier. (default: weka.classifiers.rules.ZeroR)
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
Options specific to classifier weka.classifiers.rules.ZeroR:
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
-S <dbl> Lowest value for hi classifier (default: 10)
-P <dbl> Highest value for lo classifier (default: 15)
-E <dbl> Decision boundary for hi/lo classifier (default: 12.5)
-F Full name of hi classifier. (default: weka.classifiers.rules.ZeroR)
-W Full name of base classifier. (default: weka.classifiers.rules.ZeroR)
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
Options specific to classifier weka.classifiers.rules.ZeroR:
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
Options specific to classifier weka.classifiers.rules.ZeroR:
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
-G Full name of lo classifier. (default: weka.classifiers.rules.ZeroR)
-W Full name of base classifier. (default: weka.classifiers.rules.ZeroR)
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
Options specific to classifier weka.classifiers.rules.ZeroR:
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
Options specific to classifier weka.classifiers.rules.ZeroR:
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
- Version:
- $Revision: 6936 $
- Author:
- Dale?
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected weka.classifiers.Classifierm_loClassifierprotected doublem_loHipointprotected doublem_splitpoint
-
Constructor Summary
Constructors Constructor Description HighLowSplitSingleClassifier()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidbuildClassifier(weka.core.Instances data)Builds the classifier.doubleclassifyInstance(weka.core.Instance inst)Returns the prediction.protected String[]defaultClassifierOptions()String describing options for default classifier.protected StringdefaultClassifierString()String describing default classifier.weka.core.CapabilitiesgetCapabilities()Returns default capabilities of the base classifier.doublegetLoHipoint()String[]getOptions()Gets the current option settings for the OptionHandler.StringgetRevision()doublegetSplitpoint()StringglobalInfo()Returns a string describing classifier.EnumerationlistOptions()Returns an enumeration describing the available options.StringloHipointTipText()static voidmain(String[] argv)Main method for running this class.voidsetLoHipoint(double l)voidsetOptions(String[] options)Sets the OptionHandler's options using the given list.voidsetSplitpoint(double s)StringsplitpointTipText()StringtoString()Returns description of classifier.-
Methods inherited from class weka.classifiers.SingleClassifierEnhancer
classifierTipText, getClassifier, getClassifierSpec, postExecution, preExecution, setClassifier
-
Methods inherited from class weka.classifiers.AbstractClassifier
batchSizeTipText, debugTipText, distributionForInstance, distributionsForInstances, doNotCheckCapabilitiesTipText, forName, getBatchSize, getDebug, getDoNotCheckCapabilities, getNumDecimalPlaces, implementsMoreEfficientBatchPrediction, makeCopies, makeCopy, numDecimalPlacesTipText, run, runClassifier, setBatchSize, setDebug, setDoNotCheckCapabilities, setNumDecimalPlaces
-
-
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing classifier.- Returns:
- a description suitable for displaying in the explorer/experimenter gui
-
defaultClassifierString
protected String defaultClassifierString()
String describing default classifier.- Overrides:
defaultClassifierStringin classweka.classifiers.SingleClassifierEnhancer
-
defaultClassifierOptions
protected String[] defaultClassifierOptions()
String describing options for default classifier.- Overrides:
defaultClassifierOptionsin classweka.classifiers.SingleClassifierEnhancer
-
listOptions
public Enumeration listOptions()
Returns an enumeration describing the available options.- Specified by:
listOptionsin interfaceweka.core.OptionHandler- Overrides:
listOptionsin classweka.classifiers.SingleClassifierEnhancer- Returns:
- an enumeration of all the available options.
-
setOptions
public void setOptions(String[] options) throws Exception
Sets the OptionHandler's options using the given list. All options will be set (or reset) during this call (i.e. incremental setting of options is not possible). Valid options are:
-W Full name of base classifier. (default: weka.classifiers.rules.ZeroR)
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
Options specific to classifier weka.classifiers.rules.ZeroR:
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
-S <dbl> Lowest value for hi classifier (default: 10)
-P <dbl> Highest value for lo classifier (default: 15)
-E <dbl> Decision boundary for hi/lo classifier (default: 12.5)
-F Full name of hi classifier. (default: weka.classifiers.rules.ZeroR)
-W Full name of base classifier. (default: weka.classifiers.rules.ZeroR)
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
Options specific to classifier weka.classifiers.rules.ZeroR:
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
Options specific to classifier weka.classifiers.rules.ZeroR:
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
-G Full name of lo classifier. (default: weka.classifiers.rules.ZeroR)
-W Full name of base classifier. (default: weka.classifiers.rules.ZeroR)
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
Options specific to classifier weka.classifiers.rules.ZeroR:
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
Options specific to classifier weka.classifiers.rules.ZeroR:
-output-debug-info If set, classifier is run in debug mode and may output additional info to the console
-do-not-check-capabilities If set, classifier capabilities are not checked before classifier is built (use with caution).
- Specified by:
setOptionsin interfaceweka.core.OptionHandler- Overrides:
setOptionsin classweka.classifiers.SingleClassifierEnhancer- Parameters:
options- the list of options as an array of strings- Throws:
Exception- if an option is not supported
-
getOptions
public String[] getOptions()
Gets the current option settings for the OptionHandler.- Specified by:
getOptionsin interfaceweka.core.OptionHandler- Overrides:
getOptionsin classweka.classifiers.SingleClassifierEnhancer- Returns:
- the list of current option settings as an array of strings
-
getLoHipoint
public double getLoHipoint()
-
setLoHipoint
public void setLoHipoint(double l)
-
loHipointTipText
public String loHipointTipText()
-
getSplitpoint
public double getSplitpoint()
-
setSplitpoint
public void setSplitpoint(double s)
-
splitpointTipText
public String splitpointTipText()
-
getCapabilities
public weka.core.Capabilities getCapabilities()
Returns default capabilities of the base classifier.- Specified by:
getCapabilitiesin interfaceweka.core.CapabilitiesHandler- Specified by:
getCapabilitiesin interfaceweka.classifiers.Classifier- Overrides:
getCapabilitiesin classweka.classifiers.SingleClassifierEnhancer- Returns:
- the capabilities of the base classifier
-
buildClassifier
public void buildClassifier(weka.core.Instances data) throws ExceptionBuilds the classifier.- Specified by:
buildClassifierin interfaceweka.classifiers.Classifier- Parameters:
data- the training data- Throws:
Exception- if something goes wrong
-
classifyInstance
public double classifyInstance(weka.core.Instance inst) throws ExceptionReturns the prediction.- Specified by:
classifyInstancein interfaceweka.classifiers.Classifier- Overrides:
classifyInstancein classweka.classifiers.AbstractClassifier- Throws:
Exception
-
toString
public String toString()
Returns description of classifier.
-
getRevision
public String getRevision()
- Specified by:
getRevisionin interfaceweka.core.RevisionHandler- Overrides:
getRevisionin classweka.classifiers.AbstractClassifier
-
main
public static void main(String[] argv)
Main method for running this class.- Parameters:
argv- the options
-
-