Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
10/29/15 20:39:11 (8 years ago)
Author:
gkronber
Message:

#1998: minor changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis/3.4/OnlineCalculators/ConfusionMatrixCalculator.cs

    r9119 r13091  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    3131      }
    3232
    33       IEnumerable<double> classValues = originalValues.Distinct();
    34       IEnumerable<double> estimatedClassValues = estimatedValues.Distinct();
     33      var  classValues = originalValues.Distinct().ToList();
     34      var estimatedClassValues = estimatedValues.Distinct().ToList();
    3535
    36       if (!estimatedClassValues.All(x => originalValues.Contains(x))) {
     36      if (!estimatedClassValues.All(x => classValues.Contains(x))) {
    3737        errorState = OnlineCalculatorError.InvalidValueAdded;
    3838        return null;
    3939      }
    4040
    41       int classes = classValues.Count();
     41      int classes = classValues.Count;
    4242      double[,] confusionMatrix = new double[classes, classes];
    4343
Note: See TracChangeset for help on using the changeset viewer.