jml.feature.selection
Class SupervisedFeatureSelection

java.lang.Object
  extended by jml.feature.selection.FeatureSelection
      extended by jml.feature.selection.SupervisedFeatureSelection
Direct Known Subclasses:
JointL21NormsMinimization

public class SupervisedFeatureSelection
extends FeatureSelection

Abstract class for supervised feature selection algorithms.

Version:
1.0, Feb. 4th, 2012
Author:
Mingjie Qian

Field Summary
private  int nClass
          Number of classes.
protected  org.apache.commons.math.linear.RealMatrix Y
          An n x c label matrix.
 
Fields inherited from class jml.feature.selection.FeatureSelection
W, X
 
Constructor Summary
SupervisedFeatureSelection()
           
 
Method Summary
 void feedLabels(double[][] labels)
          Feed labels for this supervised feature selection algorithm.
 void feedLabels(int[] labels)
          Feed labels for this supervised feature selection algorithm.
 void feedLabels(org.apache.commons.math.linear.RealMatrix Y)
          Feed labels for this supervised feature selection algorithm.
 org.apache.commons.math.linear.RealMatrix getY()
          Get label matrix.
 void run()
          Do feature selection.
 
Methods inherited from class jml.feature.selection.FeatureSelection
feedData, feedData, getW, getX
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

Y

protected org.apache.commons.math.linear.RealMatrix Y
An n x c label matrix.


nClass

private int nClass
Number of classes.

Constructor Detail

SupervisedFeatureSelection

public SupervisedFeatureSelection()
Method Detail

feedLabels

public void feedLabels(org.apache.commons.math.linear.RealMatrix Y)
Feed labels for this supervised feature selection algorithm.

Parameters:
Y - an n x c label matrix

feedLabels

public void feedLabels(double[][] labels)
Feed labels for this supervised feature selection algorithm.

Parameters:
labels - an n x c 2D double array

feedLabels

public void feedLabels(int[] labels)
Feed labels for this supervised feature selection algorithm.

Parameters:
labels - any integer array holding the original integer labels

run

public void run()
Description copied from class: FeatureSelection
Do feature selection.

Specified by:
run in class FeatureSelection

getY

public org.apache.commons.math.linear.RealMatrix getY()
Get label matrix.

Returns:
an n x c label matrix