public class CostSensitiveClassifierSplitEvaluator extends ClassifierSplitEvaluator
-W <class name> The full class name of the classifier. eg: weka.classifiers.bayes.NaiveBayes
-C <index> The index of the class for which IR statistics are to be output. (default 1)
-I <index> The index of an attribute to output in the results. This attribute should identify an instance in order to know which instances are in the test set of a cross validation. if 0 no output (default 0).
-P Add target and prediction columns to the result for each fold.
Options specific to classifier weka.classifiers.rules.ZeroR:
-D If set, classifier is run in debug mode and may output additional info to the console
-D <directory> Name of a directory to search for cost files when loading costs on demand (default current directory).All options after -- will be passed to the classifier.
Constructor and Description |
---|
CostSensitiveClassifierSplitEvaluator() |
Modifier and Type | Method and Description |
---|---|
java.io.File |
getOnDemandDirectory()
Returns the directory that will be searched for cost files when
loading on demand.
|
java.lang.String[] |
getOptions()
Gets the current settings of the Classifier.
|
java.lang.Object[] |
getResult(Instances train,
Instances test)
Gets the results for the supplied train and test datasets.
|
java.lang.String[] |
getResultNames()
Gets the names of each of the result columns produced for a single run.
|
java.lang.Object[] |
getResultTypes()
Gets the data types of each of the result columns produced for a
single run.
|
java.lang.String |
getRevision()
Returns the revision string.
|
java.lang.String |
globalInfo()
Returns a string describing this split evaluator
|
java.util.Enumeration |
listOptions()
Returns an enumeration describing the available options..
|
java.lang.String |
onDemandDirectoryTipText()
Returns the tip text for this property
|
void |
setOnDemandDirectory(java.io.File newDir)
Sets the directory that will be searched for cost files when
loading on demand.
|
void |
setOptions(java.lang.String[] options)
Parses a given list of options.
|
java.lang.String |
toString()
Returns a text description of the split evaluator.
|
classifierTipText, enumerateMeasures, getAttributeID, getClassForIRStatistics, getClassifier, getKey, getKeyNames, getKeyTypes, getMeasure, getPredTargetColumn, getRawResultOutput, setAdditionalMeasures, setAttributeID, setClassForIRStatistics, setClassifier, setClassifierName, setPredTargetColumn
public CostSensitiveClassifierSplitEvaluator()
public java.lang.String globalInfo()
globalInfo
in class ClassifierSplitEvaluator
public java.util.Enumeration listOptions()
listOptions
in interface OptionHandler
listOptions
in class ClassifierSplitEvaluator
public void setOptions(java.lang.String[] options) throws java.lang.Exception
-W <class name> The full class name of the classifier. eg: weka.classifiers.bayes.NaiveBayes
-C <index> The index of the class for which IR statistics are to be output. (default 1)
-I <index> The index of an attribute to output in the results. This attribute should identify an instance in order to know which instances are in the test set of a cross validation. if 0 no output (default 0).
-P Add target and prediction columns to the result for each fold.
Options specific to classifier weka.classifiers.rules.ZeroR:
-D If set, classifier is run in debug mode and may output additional info to the console
-D <directory> Name of a directory to search for cost files when loading costs on demand (default current directory).All options after -- will be passed to the classifier.
setOptions
in interface OptionHandler
setOptions
in class ClassifierSplitEvaluator
options
- the list of options as an array of stringsjava.lang.Exception
- if an option is not supportedpublic java.lang.String[] getOptions()
getOptions
in interface OptionHandler
getOptions
in class ClassifierSplitEvaluator
public java.lang.String onDemandDirectoryTipText()
public java.io.File getOnDemandDirectory()
public void setOnDemandDirectory(java.io.File newDir)
newDir
- The cost file search directory.public java.lang.Object[] getResultTypes()
getResultTypes
in interface SplitEvaluator
getResultTypes
in class ClassifierSplitEvaluator
public java.lang.String[] getResultNames()
getResultNames
in interface SplitEvaluator
getResultNames
in class ClassifierSplitEvaluator
public java.lang.Object[] getResult(Instances train, Instances test) throws java.lang.Exception
getResult
in interface SplitEvaluator
getResult
in class ClassifierSplitEvaluator
train
- the training Instances.test
- the testing Instances.java.lang.Exception
- if a problem occurs while getting the resultspublic java.lang.String toString()
toString
in class ClassifierSplitEvaluator
public java.lang.String getRevision()
getRevision
in interface RevisionHandler
getRevision
in class ClassifierSplitEvaluator