Package org.fnlp.ml.classifier.bayes

Examples of org.fnlp.ml.classifier.bayes.BayesClassifier.fS_CS()


    float[] percents_cs=new float[]{1.0f,0.9f,0.8f,0.7f,0.5f,0.3f,0.2f,0.1f};
    int[] counts_cs=new int[10];
    for(int test=0;test<percents_cs.length;test++){
      System.out.println("Testing Bayes"+percents_cs[test]+"...");
      if(test!=0)
        bayes.fS_CS(percents_cs[test]);
      int count=0;
      for(int i=0;i<testset.size();i++){
        Instance data = testset.getInstance(i);
        Integer gold = (Integer) data.getTarget();
        Predict<String> pres=bayes.classify(data, Type.STRING, 3);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.