Example usage for weka.classifiers AbstractClassifier runClassifier

List of usage examples for weka.classifiers AbstractClassifier runClassifier

Introduction

In this page you can find the example usage for weka.classifiers AbstractClassifier runClassifier.

Prototype

public static void runClassifier(Classifier classifier, String[] options) 

Source Link

Document

runs the classifier instance with the given options.

Usage

From source file:ensembles.RandomForests.java

public void runClassBalanced() {
    ClassBalancedND classBalanced = new ClassBalancedND();
    Bagging f = new Bagging();
    f.setClassifier(classBalanced);/*from   w  w  w.ja va2 s. c o  m*/
    String[] arg = new String[2];
    arg[0] = "-t"; //training
    arg[1] = "/Users/katie/NetBeansProjects/weka/trunk/packages/internal/ensemblesOfNestedDichotomies/out/nd/mfeatFac/NDfold1.arff";
    //  arg[2] = "-T";
    //  arg[3] = "/Users/katie/NetBeansProjects/weka/trunk/packages/internal/ensemblesOfNestedDichotomies/out/nd/mfeatFac/NDtest1.arff";
    //   arg[2] = "-W"; //full name of the base classifier
    //   arg[3] = "weka.classifiers.functions.Logistic";
    AbstractClassifier.runClassifier(f, arg);
}