public interface FeatureSelector
Interface of feature selector which often work tegether with text classifiers.
Copyright: Copyright (c) 2005
Company: IST, Drexel University
| Modifier and Type | Method and Description |
|---|---|
int |
getSelectedFeatureNum() |
boolean |
isSelected(int originalFeatureIndex) |
int |
map(int originalFeatureIndex)
Map the old feature index to the index in the new feature space.
|
void |
setSelectedFeatures(int[] selectedFeatures)
Manually set selected features.
|
void |
train(IndexReader indexReader,
DocClassSet trainingSet)
This method chooses a subset of features for text classification
|
void |
train(SparseMatrix doctermMatrix,
DocClassSet trainingSet)
This method chooses a subset of features for text classification.
|
void train(SparseMatrix doctermMatrix, DocClassSet trainingSet)
doctermMatrix - the document-term matrix a classifer is working ontrainingSet - the labeled training document setvoid train(IndexReader indexReader, DocClassSet trainingSet)
indexReader - the index reader a classifer is working ontrainingSet - the labeled training document setboolean isSelected(int originalFeatureIndex)
originalFeatureIndex - the index of the feature in the old feature spaceint getSelectedFeatureNum()
int map(int originalFeatureIndex)
originalFeatureIndex - the index of the feature before feature selectionvoid setSelectedFeatures(int[] selectedFeatures)
selectedFeatures - each elements contains the index of the selected feature in the old feature space.
The selected feature must be in the ascending order in the input array.Copyright © 2018 JULIE Lab, Germany. All rights reserved.