|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectweka.attributeSelection.ASSearch
weka.attributeSelection.TPPAttributeSearch
public class TPPAttributeSearch
Class that uses Targeted Projection Pursuit as a attribute selection algorithm. TPP is used to produce an N-dimensional (usually N=2) projection of the data that separates classes in the data. The components in the resulting projection are then used to rank each attribute. In order to reduce execution time (if the number of attributes is large, say >1000) we can optionally use IG to preselect a subset of attributes. The user can also see the resulting views of the data as they are produced. Should be used with a TPPAttributeEvaluation evaluator (which is a dummy evaluator that does nothing). The user can also specify the maximum number of cycles in training and/or a convergence limit
See C.Haddow, J.Perry, M.Durrant and J.Faith, "Predicting Functional Residues of Protein Sequence Alignments as a Feature Selection Task" , International Journal of Data Mining in Bioinformatics, 2011
Constructor Summary | |
---|---|
TPPAttributeSearch()
|
Method Summary | |
---|---|
int |
getCalculatedNumToSelect()
|
Capabilities |
getCapabilities()
Returns the capabilities of this evaluator. |
double |
getConvergenceLimit()
|
int |
getEpochLimit()
|
boolean |
getGenerateRanking()
This class will always rank attributes, so this method always returns true |
int |
getNumOutputDimensions()
The number of output dimensions (default=2) |
int |
getNumToPreSelect()
The number of attributes to pre-select using IG |
int |
getNumToSelect()
|
java.lang.String[] |
getOptions()
Gets the current settings of attributes. |
boolean |
getShowView()
Whether to show the projected data as it is separated |
TechnicalInformation |
getTechnicalInformation()
Returns an instance of a TechnicalInformation object, containing detailed information about the technical background of this class, e.g., paper reference or book this class is based on. |
double |
getThreshold()
|
java.lang.String |
globalInfo()
|
java.util.Enumeration |
listOptions()
Returns an enumeration describing the available options. |
static void |
main(java.lang.String[] a)
Test method |
void |
modelChanged(TPPModelEvent e)
|
double[][] |
rankedAttributes()
|
int[] |
search(ASEvaluation evaluator,
Instances data)
Use TPP to select attributes. |
void |
setConvergenceLimit(double convergenceLimit)
The limit at which TPP is treated as converged |
void |
setEpochLimit(int epochLimit)
The maximum number of training cycles that TPP should run for |
void |
setGenerateRanking(boolean doRanking)
Whether to rank the selected attributes. |
void |
setNumOutputDimensions(int numOutputDimensions)
The number of output dimensions (default=2) |
void |
setNumToPreSelect(int numToPreSelect)
The number of attributes to preselect using IG. |
void |
setNumToSelect(int numToSelect)
The number of attributes to select. |
void |
setOptions(java.lang.String[] options)
Parses a given list of options. |
void |
setShowView(boolean showView)
Whether to show the projected data as it is separated |
void |
setThreshold(double threshold)
|
java.lang.String |
toString()
|
void |
windowActivated(java.awt.event.WindowEvent e)
|
void |
windowClosed(java.awt.event.WindowEvent e)
|
void |
windowClosing(java.awt.event.WindowEvent e)
|
void |
windowDeactivated(java.awt.event.WindowEvent e)
|
void |
windowDeiconified(java.awt.event.WindowEvent e)
|
void |
windowIconified(java.awt.event.WindowEvent e)
|
void |
windowOpened(java.awt.event.WindowEvent e)
|
Methods inherited from class weka.attributeSelection.ASSearch |
---|
forName, getRevision, makeCopies |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public TPPAttributeSearch()
Method Detail |
---|
public java.lang.String globalInfo()
public TechnicalInformation getTechnicalInformation()
getTechnicalInformation
in interface TechnicalInformationHandler
public int[] search(ASEvaluation evaluator, Instances data) throws java.lang.Exception
search
in class ASSearch
java.lang.Exception
public void modelChanged(TPPModelEvent e)
modelChanged
in interface TPPModelEventListener
public void windowActivated(java.awt.event.WindowEvent e)
windowActivated
in interface java.awt.event.WindowListener
public void windowClosed(java.awt.event.WindowEvent e)
windowClosed
in interface java.awt.event.WindowListener
public void windowClosing(java.awt.event.WindowEvent e)
windowClosing
in interface java.awt.event.WindowListener
public void windowDeactivated(java.awt.event.WindowEvent e)
windowDeactivated
in interface java.awt.event.WindowListener
public void windowDeiconified(java.awt.event.WindowEvent e)
windowDeiconified
in interface java.awt.event.WindowListener
public void windowIconified(java.awt.event.WindowEvent e)
windowIconified
in interface java.awt.event.WindowListener
public void windowOpened(java.awt.event.WindowEvent e)
windowOpened
in interface java.awt.event.WindowListener
public int getCalculatedNumToSelect()
getCalculatedNumToSelect
in interface RankedOutputSearch
public boolean getGenerateRanking()
getGenerateRanking
in interface RankedOutputSearch
public int getNumToSelect()
getNumToSelect
in interface RankedOutputSearch
public int getNumToPreSelect()
public double getThreshold()
getThreshold
in interface RankedOutputSearch
public boolean getShowView()
public void setShowView(boolean showView)
public double[][] rankedAttributes() throws java.lang.Exception
rankedAttributes
in interface RankedOutputSearch
java.lang.Exception
public void setGenerateRanking(boolean doRanking)
setGenerateRanking
in interface RankedOutputSearch
public void setNumToSelect(int numToSelect)
setNumToSelect
in interface RankedOutputSearch
public void setNumToPreSelect(int numToPreSelect)
public void setThreshold(double threshold)
setThreshold
in interface RankedOutputSearch
public int getEpochLimit()
public void setEpochLimit(int epochLimit)
public double getConvergenceLimit()
public void setConvergenceLimit(double convergenceLimit)
public int getNumOutputDimensions()
public void setNumOutputDimensions(int numOutputDimensions)
public java.util.Enumeration listOptions()
listOptions
in interface OptionHandler
public void setOptions(java.lang.String[] options) throws java.lang.Exception
-N <number of attributes> The number of attributes to select. -P <number of attributes to preselect> The number of attributes to preselect. -V; Show resulting data visualisation. -L <convergence limit> -C <maximum number of training cycles> -D <number of output dimensions>
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 toString()
toString
in class java.lang.Object
public Capabilities getCapabilities()
getCapabilities
in interface CapabilitiesHandler
Capabilities
public static void main(java.lang.String[] a) throws java.lang.Exception
java.lang.Exception
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |