1

I want to classify my data through bernoulli classifier in lingpipe If someone has the working method for it, please share

1 Answers1

0

http://java2s.com/Open-Source/Java/Natural-Language-Processing/LingPipe/com/aliasi/test/unit/classify/BernoulliClassifierTest.java.htm

I.e.

FeatureExtractor FEATURE_EXTRACTOR
    = new TokenFeatureExtractor(IndoEuropeanTokenizerFactory.INSTANCE);
...
BernoulliClassifier classifier
        = new BernoulliClassifier(FEATURE_EXTRACTOR);

Then use handle() to add training data, and classify() to get answers out.


To find this I googled on "Bernoulli classifier in Lingpipe" (without the quotes). I found the API docs, and saw no example usage and that it is poor quality. So, I guessed there might be a unit test, as Java programmers are quite anal about testing. So then I googled for "bernoulliClassifier lingpipe test" (again, without the quotes).

(By "poor quality" docs, I mean the function descriptions just repeat the function names, and add no information.)

Darren Cook
  • 27,837
  • 13
  • 117
  • 217