Class AlgorithmLDA

java.lang.Object
  extended by Algorithm
      extended by AlgorithmLDA
All Implemented Interfaces:
java.lang.Runnable

public class AlgorithmLDA
extends Algorithm

Implements the Linear Discriminant Analysis Algorithm


Constructor Summary
AlgorithmLDA()
           
 
Method Summary
 void betweenClass(Matrix M)
          Determines the between class scatter matrix for the class independent linear discrimination algorithm
 void computeDecisionRegions()
          Computes the line of discrimination for class independent LDA
 void computeErrors()
          Counts the data points in each set in error and displays them on the text message window
 void displayMatrices()
          Display two matrices - covariance matrix and the transformation matrix in the text message window
 boolean initialize()
          Overrides the initialize() method in the base class.
 void run()
          Implementation of the run function from the Runnable interface.
 void transformLDA(DataPoints d, Matrix S)
          Transforms a given set of points to a new space using the class independent linear discrimination analysis algorithm
 void withinClass(Matrix M)
          Determines the within class scatter matrix
 
Methods inherited from class Algorithm
computeMeans, disableControl, enableControl, nextStep, prevStep, scaleToFitData, setDataPoints, setInputPanel, setOutputPanel, setProcessBox
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AlgorithmLDA

public AlgorithmLDA()
Method Detail

initialize

public boolean initialize()
Overrides the initialize() method in the base class. Initializes member data and prepares for execution of first step. This method "resets" the algorithm.

Specified by:
initialize in class Algorithm
Returns:
Returns true.

withinClass

public void withinClass(Matrix M)
Determines the within class scatter matrix

Parameters:
M - Matrix for within class scatter matrix
See Also:
Matrix

betweenClass

public void betweenClass(Matrix M)
Determines the between class scatter matrix for the class independent linear discrimination algorithm

Parameters:
M - Matrix for storing between class scatter matrix
See Also:
Matrix

run

public void run()
Implementation of the run function from the Runnable interface. Determines what the current step is and calls the appropriate method.

Specified by:
run in interface java.lang.Runnable
Specified by:
run in class Algorithm

displayMatrices

public void displayMatrices()
Display two matrices - covariance matrix and the transformation matrix in the text message window


transformLDA

public void transformLDA(DataPoints d,
                         Matrix S)
Transforms a given set of points to a new space using the class independent linear discrimination analysis algorithm

Parameters:
d - Datapoint - input data point
S - Matrix containing between class to within class ratio
See Also:
DataPoints, Matrix

computeDecisionRegions

public void computeDecisionRegions()
Computes the line of discrimination for class independent LDA


computeErrors

public void computeErrors()
Counts the data points in each set in error and displays them on the text message window