public abstract class Classifier
extends java.lang.Object
Base class for all classifiers (knowledge representations)
Modifier and Type | Field and Description |
---|---|
protected double |
accuracy |
protected boolean |
bloatControlDone |
protected double |
exceptionsLength |
protected double |
fitness |
protected boolean |
isEvaluated |
protected int |
numAliveRules |
protected int |
numRules |
protected int |
positionRuleMatch |
protected double |
theoryLength |
Constructor and Description |
---|
Classifier() |
Modifier and Type | Method and Description |
---|---|
boolean |
compareToIndividual(Classifier ind)
This function returns true if this individual is better than
the the individual passed as a parameter.
|
void |
computePerformance() |
abstract double |
computeTheoryLength() |
abstract Classifier |
copy() |
abstract Classifier[] |
crossoverClassifiers(Classifier _parent2) |
abstract void |
crossoverRSW(Classifier[] parents,
int numParents) |
abstract void |
deleteRules(int[] whichRules) |
abstract void |
doLocalSearch() |
abstract int |
doMatch(InstanceWrapper ins) |
abstract void |
doMutation() |
abstract void |
doSpecialStage(int stage) |
double |
getExceptionsLength() |
double |
getFitness() |
boolean |
getIsEvaluated() |
abstract double |
getLength() |
abstract int |
getNiche() |
int |
getNumAliveRules() |
abstract int |
getNumNiches() |
abstract int |
getNumRules() |
int |
getPositionRuleMatch()
positionRuleMatch contains the position within the classifier
(e.g. the rule) that matched the last classified input
instance
|
double |
getTheoryLength() |
abstract void |
initRandomClassifier() |
abstract int |
numSpecialStages() |
abstract void |
printClassifier() |
void |
resetPerformance() |
void |
setAccuracy(double _accuracy) |
void |
setExceptionsLength(double _exceptionsLength) |
void |
setFitness(double _fitness) |
void |
setIsEvaluated(boolean _isEvaluated) |
void |
setNumAliveRules(int _numAliveRules) |
void |
setPositionRuleMatch(int _positionRuleMatch) |
protected boolean isEvaluated
protected boolean bloatControlDone
protected double accuracy
protected double fitness
protected double exceptionsLength
protected double theoryLength
protected int numAliveRules
protected int positionRuleMatch
protected int numRules
public abstract void initRandomClassifier()
public abstract int doMatch(InstanceWrapper ins)
public abstract int getNumRules()
public abstract void deleteRules(int[] whichRules)
public abstract Classifier[] crossoverClassifiers(Classifier _parent2)
public abstract void doMutation()
public abstract Classifier copy()
public abstract void printClassifier()
public boolean getIsEvaluated()
public void setIsEvaluated(boolean _isEvaluated)
public void setAccuracy(double _accuracy)
public double getFitness()
public void setFitness(double _fitness)
public double getExceptionsLength()
public void setExceptionsLength(double _exceptionsLength)
public int getNumAliveRules()
public void setNumAliveRules(int _numAliveRules)
public void resetPerformance()
public void computePerformance()
public int getPositionRuleMatch()
public void setPositionRuleMatch(int _positionRuleMatch)
public abstract double getLength()
public double getTheoryLength()
public abstract double computeTheoryLength()
public boolean compareToIndividual(Classifier ind)
public abstract int getNiche()
public abstract int getNumNiches()
public abstract int numSpecialStages()
public abstract void doSpecialStage(int stage)
public abstract void doLocalSearch()
public abstract void crossoverRSW(Classifier[] parents, int numParents)