time = System.currentTimeMillis() - time;
log.info("Classification Time: {}", DFUtils.elapsedTime(time));
if (analyze) {
if (dataset.isNumerical(dataset.getLabelId())) {
RegressionResultAnalyzer regressionAnalyzer = new RegressionResultAnalyzer();
double[][] results = new double[resList.size()][2];
regressionAnalyzer.setInstances(resList.toArray(results));
log.info("{}", regressionAnalyzer);
} else {
ResultAnalyzer analyzer = new ResultAnalyzer(Arrays.asList(dataset.labels()), "unknown");
for (double[] r : resList) {
analyzer.addInstance(dataset.getLabelString(r[0]),