Last change
on this file since 12 was
2,
checked in by sherbold, 10 years ago
|
|
-
Property svn:mime-type set to
text/plain
|
File size:
761 bytes
|
Line | |
---|
1 | package de.ugoe.cs.cpdp.eval;
|
---|
2 |
|
---|
3 | import weka.classifiers.Classifier;
|
---|
4 | import weka.classifiers.Evaluation;
|
---|
5 | import weka.core.Instances;
|
---|
6 |
|
---|
7 | /**
|
---|
8 | * Implements the {@link AbstractWekaEvaluation} for evaluation on the test data.
|
---|
9 | * @author Steffen Herbold
|
---|
10 | *
|
---|
11 | */
|
---|
12 | public class NormalWekaEvaluation extends AbstractWekaEvaluation {
|
---|
13 |
|
---|
14 | /**
|
---|
15 | * @see de.ugoe.cs.cpdp.eval.AbstractWekaEvaluation#createEvaluator(weka.core.Instances, weka.classifiers.Classifier)
|
---|
16 | */
|
---|
17 | @Override
|
---|
18 | protected Evaluation createEvaluator(Instances testdata, Classifier classifier) {
|
---|
19 | try {
|
---|
20 | final Evaluation eval = new Evaluation(testdata);
|
---|
21 | eval.evaluateModel(classifier, testdata);
|
---|
22 | return eval;
|
---|
23 | } catch (Exception e) {
|
---|
24 | throw new RuntimeException(e);
|
---|
25 | }
|
---|
26 | }
|
---|
27 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.