public final class CategoricalPrediction extends Prediction
NumericPrediction,
Serialized Form| Constructor and Description |
|---|
CategoricalPrediction(double[] categoryCounts) |
CategoricalPrediction(int[] categoryCounts) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
double[] |
getCategoryCounts() |
double[] |
getCategoryProbabilities() |
FeatureType |
getFeatureType() |
int |
getMostProbableCategoryEncoding() |
int |
hashCode() |
String |
toString() |
void |
update(Example train) |
void |
update(int encoding,
int count) |
getCountpublic CategoricalPrediction(int[] categoryCounts)
public CategoricalPrediction(double[] categoryCounts)
categoryCounts - "counts" for each category, which may be fractionalpublic double[] getCategoryCounts()
public double[] getCategoryProbabilities()
public int getMostProbableCategoryEncoding()
public FeatureType getFeatureType()
getFeatureType in class PredictionFeatureType.CATEGORICALpublic void update(Example train)
update in class Predictionpublic void update(int encoding,
int count)
public String toString()
toString in class PredictionCopyright © 2014–2018. All rights reserved.