public class TFFCountSentiment extends Object implements Sentiment, BipolarSentimentProvider, WeightedBipolarSentimentProvider, DiscreteCountBipolarSentimentProvider
Constructor and Description |
---|
TFFCountSentiment()
all weights set to 0
|
TFFCountSentiment(int total) |
Modifier and Type | Method and Description |
---|---|
Map<String,?> |
asMap() |
BipolarSentiment |
bipolar() |
BipolarSentiment |
bipolar(double deltaThresh) |
static BipolarSentiment |
bipolar(TFF.Clue clue) |
DiscreteCountBipolarSentiment |
countBipolarSentiment() |
boolean |
equals(Object obj) |
void |
fromMap(Map<String,?> map) |
void |
incrementClue(TFF.Clue entry,
int increment) |
WeightedBipolarSentiment |
weightedBipolar() |
public TFFCountSentiment()
public TFFCountSentiment(int total)
total
- instnatiate with a total number of wordspublic void incrementClue(TFF.Clue entry, int increment)
entry
- increment
- public BipolarSentiment bipolar()
bipolar
in interface BipolarSentimentProvider
public BipolarSentiment bipolar(double deltaThresh)
bipolar
in interface BipolarSentimentProvider
deltaThresh
- A a proportional thresholdpublic WeightedBipolarSentiment weightedBipolar()
weightedBipolar
in interface WeightedBipolarSentimentProvider
public DiscreteCountBipolarSentiment countBipolarSentiment()
countBipolarSentiment
in interface DiscreteCountBipolarSentimentProvider
public void fromMap(Map<String,?> map) throws UnrecognisedMapException
fromMap
in interface Sentiment
map
- the map containing this sentimentUnrecognisedMapException
public static BipolarSentiment bipolar(TFF.Clue clue)
clue
- TFFCountSentiment
with 1 word and 1 clue and call bipolar()