Radom Forest does not on command line execution.

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Radom Forest does not on command line execution.

wchoi1
This post has NOT been accepted by the mailing list yet.
Hello all,

I'm trying to use Random Forest Classifier, but I'm getting the following error message.

weka.core.UnsupportedAttributeTypeException: weka.classifiers.trees.RandomTree: Cannot handle numeric class!
        at weka.core.Capabilities.test(Capabilities.java:954)
        at weka.core.Capabilities.test(Capabilities.java:1110)
        at weka.core.Capabilities.test(Capabilities.java:1023)
        at weka.core.Capabilities.testWithFail(Capabilities.java:1302)
        at weka.classifiers.trees.RandomTree.buildClassifier(RandomTree.java:551)
        at weka.classifiers.Evaluation.evaluateModel(Evaluation.java:1149)
        at weka.classifiers.Classifier.runClassifier(Classifier.java:315)
        at weka.classifiers.trees.RandomTree.main(RandomTree.java:1500)

When I try on GUI mode, it works fine, but it gives me the error on command line execution.
My command line to execute the Random Forest is below.

java weka.classifiers.trees.RandomTree -K 0 -M 1.0 -S 1 -t training.arff -T testing.arff

And this is how my training file looks like.

@RELATION TRAINING

@ATTRIBUTE C1 NUMERIC
@ATTRIBUTE C2 NUMERIC
@ATTRIBUTE C3 NUMERIC
@ATTRIBUTE C4 NUMERIC
@ATTRIBUTE C5 NUMERIC
@ATTRIBUTE RESULT NUMERIC

@DATA
0 0 0 0 0 1 59.3939
1 4 0 1 0 1 69.8936
0 0 0 1 0 1 59.6274
4 0 0 0 0 1 62.8234

Any help would be appreciated!
Loading...