Set exponential bias towards confident intervals. default = 1.0
- Author:
- Mark Hall (mhall@cs.waikato.ac.nz)
- See Also:
- Serialized Form
Field Summary |
protected double |
m_bias
Bias towards more confident intervals |
protected int |
m_ClassIndex
The index of the class attribute |
protected double[][][] |
m_counts
The class counts for each interval of each attribute |
protected double[] |
m_globalCounts
The global class counts |
protected Instances |
m_Instances
The training data |
protected double[][] |
m_intervalBounds
The lower bounds for each attribute |
protected double |
m_maxEntrop
The maximum entropy for the class |
protected int |
m_NumClasses
The number of classes |
protected boolean |
m_weightByConfidence
Exponentially bias more confident intervals |
Constructor Summary |
VFI()
|
Method Summary |
java.lang.String |
biasTipText()
Returns the tip text for this property |
void |
buildClassifier(Instances instances)
Generates the classifier. |
double[] |
distributionForInstance(Instance instance)
Classifies the given test instance. |
double |
getBias()
Get the value of the bias parameter |
java.lang.String[] |
getOptions()
Gets the current settings of VFI |
boolean |
getWeightByConfidence()
Get whether feature intervals are being weighted by confidence |
java.lang.String |
globalInfo()
Returns a string describing this search method |
java.util.Enumeration |
listOptions()
Returns an enumeration describing the available options |
static void |
main(java.lang.String[] args)
Main method for testing this class. |
void |
setBias(double b)
Set the value of the exponential bias towards more confident intervals |
void |
setOptions(java.lang.String[] options)
Parses a given list of options. |
void |
setWeightByConfidence(boolean c)
Set weighting by confidence |
java.lang.String |
toString()
Returns a description of this classifier. |
java.lang.String |
weightByConfidenceTipText()
Returns the tip text for this property |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
m_ClassIndex
protected int m_ClassIndex
- The index of the class attribute
m_NumClasses
protected int m_NumClasses
- The number of classes
m_Instances
protected Instances m_Instances
- The training data
m_counts
protected double[][][] m_counts
- The class counts for each interval of each attribute
m_globalCounts
protected double[] m_globalCounts
- The global class counts
m_intervalBounds
protected double[][] m_intervalBounds
- The lower bounds for each attribute
m_maxEntrop
protected double m_maxEntrop
- The maximum entropy for the class
m_weightByConfidence
protected boolean m_weightByConfidence
- Exponentially bias more confident intervals
m_bias
protected double m_bias
- Bias towards more confident intervals
VFI
public VFI()
globalInfo
public java.lang.String globalInfo()
- Returns a string describing this search method
- Returns:
- a description of the search method suitable for
displaying in the explorer/experimenter gui
listOptions
public java.util.Enumeration listOptions()
- Returns an enumeration describing the available options
- Specified by:
listOptions
in interface OptionHandler
- Returns:
- an enumeration of all the available options
setOptions
public void setOptions(java.lang.String[] options)
throws java.lang.Exception
- Parses a given list of options. Valid options are:
-C
Don't weight voting intervals by confidence.
-B
Set exponential bias towards confident intervals. default = 1.0
- Specified by:
setOptions
in interface OptionHandler
- Parameters:
options
- the list of options as an array of strings- Throws:
java.lang.Exception
- if an option is not supported
weightByConfidenceTipText
public java.lang.String weightByConfidenceTipText()
- Returns the tip text for this property
- Returns:
- tip text for this property suitable for
displaying in the explorer/experimenter gui
setWeightByConfidence
public void setWeightByConfidence(boolean c)
- Set weighting by confidence
- Parameters:
c
- true if feature intervals are to be weighted by confidence
getWeightByConfidence
public boolean getWeightByConfidence()
- Get whether feature intervals are being weighted by confidence
- Returns:
- true if weighting by confidence is selected
biasTipText
public java.lang.String biasTipText()
- Returns the tip text for this property
- Returns:
- tip text for this property suitable for
displaying in the explorer/experimenter gui
setBias
public void setBias(double b)
- Set the value of the exponential bias towards more confident intervals
- Parameters:
b
- the value of the bias parameter
getBias
public double getBias()
- Get the value of the bias parameter
- Returns:
- the bias parameter
getOptions
public java.lang.String[] getOptions()
- Gets the current settings of VFI
- Specified by:
getOptions
in interface OptionHandler
- Returns:
- an array of strings suitable for passing to setOptions()
buildClassifier
public void buildClassifier(Instances instances)
throws java.lang.Exception
- Generates the classifier.
- Overrides:
buildClassifier
in class Classifier
- Parameters:
instances
- set of instances serving as training data- Throws:
java.lang.Exception
- if the classifier has not been generated successfully
toString
public java.lang.String toString()
- Returns a description of this classifier.
- Overrides:
toString
in class java.lang.Object
- Returns:
- a description of this classifier as a string.
distributionForInstance
public double[] distributionForInstance(Instance instance)
throws java.lang.Exception
- Classifies the given test instance.
- Overrides:
distributionForInstance
in class DistributionClassifier
- Parameters:
instance
- the instance to be classified- Returns:
- the predicted class for the instance
- Throws:
java.lang.Exception
- if the instance can't be classified
main
public static void main(java.lang.String[] args)
- Main method for testing this class.
- Parameters:
args
- should contain command line arguments for evaluation
(see Evaluation).