|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectweka.associations.HotSpot
public class HotSpot
HotSpot learns a set of rules (displayed in a tree-like structure) that maximize/minimize a target variable/value of interest. With a nominal target, one might want to look for segments of the data where there is a high probability of a minority value occuring (given the constraint of a minimum support). For a numeric target, one might be interested in finding segments where this is higher on average than in the whole data set. For example, in a health insurance scenario, find which health insurance groups are at the highest risk (have the highest claim ratio), or, which groups have the highest average insurance payout.
Valid options are:-c <num | first | last> The target index. (default = last)
-V <num | first | last> The target value (nominal target only, default = first)
-L Minimize rather than maximize.
-S <num> Minimum value count (nominal target)/segment size (numeric target). Values between 0 and 1 are interpreted as a percentage of the total population; values > 1 are interpreted as an absolute number of instances (default = 0.3)
-M <num> Maximum branching factor (default = 2)
-I <num> Minimum improvement in target value in order to add a new branch/test (default = 0.01 (1%))
-D Output debugging info (duplicate rule lookup hash table stats)
Field Summary |
---|
Fields inherited from interface weka.core.Drawable |
---|
BayesNet, NOT_DRAWABLE, TREE |
Constructor Summary | |
---|---|
HotSpot()
Constructor |
Method Summary | |
---|---|
void |
buildAssociations(Instances instances)
Build the tree |
java.lang.String |
debugTipText()
Returns the tip text for this property |
Capabilities |
getCapabilities()
Returns default capabilities of HotSpot |
boolean |
getDebug()
Get whether debugging info is output |
int |
getMaxBranchingFactor()
Get the maximum branching factor |
boolean |
getMinimizeTarget()
Get whether to minimize the target rather than maximize |
double |
getMinImprovement()
Get the minimum improvement in the target necessary to add a test |
java.lang.String[] |
getOptions()
Gets the current settings of HotSpot. |
java.lang.String |
getRevision()
Returns the revision string. |
double |
getSupport()
Get the minimum support |
java.lang.String |
getTarget()
Get the target index as a string |
java.lang.String |
getTargetIndex()
For a nominal target, get the index of the value of interest (1-based) |
java.lang.String |
globalInfo()
Returns a string describing this classifier |
java.lang.String |
graph()
Returns a string that describes a graph representing the object. |
int |
graphType()
Returns the type of graph this scheme represents. |
java.util.Enumeration |
listOptions()
Returns an enumeration describing the available options. |
static void |
main(java.lang.String[] args)
Main method for testing this class. |
java.lang.String |
maxBranchingFactorTipText()
Returns the tip text for this property |
java.lang.String |
minimizeTargetTipText()
Returns the tip text for this property |
java.lang.String |
minImprovementTipText()
Returns the tip text for this property |
void |
resetOptions()
Reset options to their defaults |
void |
setDebug(boolean d)
Set whether debugging info is output |
void |
setMaxBranchingFactor(int b)
Set the maximum branching factor |
void |
setMinimizeTarget(boolean m)
Set whether to minimize the target rather than maximize |
void |
setMinImprovement(double i)
Set the minimum improvement in the target necessary to add a test |
void |
setOptions(java.lang.String[] options)
Parses a given list of options. |
void |
setSupport(double s)
Set the minimum support |
void |
setTarget(java.lang.String target)
Set the target index |
void |
setTargetIndex(java.lang.String index)
For a nominal target, set the index of the value of interest (1-based) |
java.lang.String |
supportTipText()
Returns the tip text for this property |
java.lang.String |
targetIndexTipText()
Returns the tip text for this property |
java.lang.String |
targetTipText()
Returns the tip text for this property |
java.lang.String |
toString()
Return the tree as a string |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public HotSpot()
Method Detail |
---|
public java.lang.String globalInfo()
public Capabilities getCapabilities()
getCapabilities
in interface Associator
getCapabilities
in interface CapabilitiesHandler
Capabilities
public void buildAssociations(Instances instances) throws java.lang.Exception
buildAssociations
in interface Associator
instances
- the training instances
java.lang.Exception
- if something goes wrongpublic java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String graph() throws java.lang.Exception
Drawable
graph
in interface Drawable
java.lang.Exception
- if the graph can't be computedpublic java.lang.String targetTipText()
public void setTarget(java.lang.String target)
target
- the target index as a string (1-based)public java.lang.String getTarget()
public java.lang.String targetIndexTipText()
public void setTargetIndex(java.lang.String index)
index
- the index of the nominal value of interestpublic java.lang.String getTargetIndex()
public java.lang.String minimizeTargetTipText()
public void setMinimizeTarget(boolean m)
m
- true if target is to be minimizedpublic boolean getMinimizeTarget()
public java.lang.String supportTipText()
public double getSupport()
public void setSupport(double s)
s
- the minimum supportpublic java.lang.String maxBranchingFactorTipText()
public void setMaxBranchingFactor(int b)
b
- the maximum branching factorpublic int getMaxBranchingFactor()
public java.lang.String minImprovementTipText()
public void setMinImprovement(double i)
i
- the minimum improvementpublic double getMinImprovement()
public java.lang.String debugTipText()
public void setDebug(boolean d)
d
- true to output debugging infopublic boolean getDebug()
public java.util.Enumeration listOptions()
listOptions
in interface OptionHandler
public void resetOptions()
public void setOptions(java.lang.String[] options) throws java.lang.Exception
-c <num | first | last> The target index. (default = last)
-V <num | first | last> The target value (nominal target only, default = first)
-L Minimize rather than maximize.
-S <num> Minimum value count (nominal target)/segment size (numeric target). Values between 0 and 1 are interpreted as a percentage of the total population; values > 1 are interpreted as an absolute number of instances (default = 0.3)
-M <num> Maximum branching factor (default = 2)
-I <num> Minimum improvement in target value in order to add a new branch/test (default = 0.01 (1%))
-D Output debugging info (duplicate rule lookup hash table stats)
setOptions
in interface OptionHandler
options
- the list of options as an array of strings
java.lang.Exception
- if an option is not supportedpublic java.lang.String[] getOptions()
getOptions
in interface OptionHandler
public java.lang.String getRevision()
getRevision
in interface RevisionHandler
public int graphType()
graphType
in interface Drawable
public static void main(java.lang.String[] args)
args
- the options
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |