public class WinnowClassifier extends Object implements Classifier<Boolean>
| Modifier and Type | Field and Description |
|---|---|
double |
demotion |
double |
promotion |
double |
threshold |
| Constructor and Description |
|---|
WinnowClassifier() |
WinnowClassifier(double promotion,
double demotion,
double threshold) |
| Modifier and Type | Method and Description |
|---|---|
Boolean |
classify(double[] features) |
double |
getDemotion() |
double |
getPromotion() |
double |
getThreshold() |
double[] |
getWeights() |
protected void |
init(int featureSize) |
void |
reset() |
void |
setDemotion(double demotion) |
void |
setPromotion(double promotion) |
void |
setThreshold(double threshold) |
void |
setWeights(double[] weights) |
String |
toString() |
void |
update(Boolean label,
double[] features) |
public double promotion
public double demotion
public double threshold
public WinnowClassifier()
public WinnowClassifier(double promotion,
double demotion,
double threshold)
public Boolean classify(double[] features)
classify in interface Classifier<Boolean>public void update(Boolean label, double[] features)
update in interface Classifier<Boolean>protected void init(int featureSize)
public void reset()
reset in interface Classifier<Boolean>public double[] getWeights()
public void setWeights(double[] weights)
public double getThreshold()
public void setThreshold(double threshold)
public double getPromotion()
public void setPromotion(double promotion)
public double getDemotion()
public void setDemotion(double demotion)
Copyright © 2013. All rights reserved.