Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
06/25/15 13:46:24 (9 years ago)
Author:
mkommend
Message:

#2276: Reintegrated branch for dataset refactoring.

Location:
trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification/3.4
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification/3.4/SymbolicClassificationModel.cs

    r12012 r12509  
    4141      : base(tree, interpreter, lowerEstimationLimit, upperEstimationLimit) { }
    4242
    43     public abstract IEnumerable<double> GetEstimatedClassValues(Dataset dataset, IEnumerable<int> rows);
     43    public abstract IEnumerable<double> GetEstimatedClassValues(IDataset dataset, IEnumerable<int> rows);
    4444    public abstract void RecalculateModelParameters(IClassificationProblemData problemData, IEnumerable<int> rows);
    4545
  • trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification/3.4/SymbolicDiscriminantFunctionClassificationModel.cs

    r12012 r12509  
    8888      var classValuesArr = classValues.ToArray();
    8989      var thresholdsArr = thresholds.ToArray();
    90       if (thresholdsArr.Length != classValuesArr.Length || thresholdsArr.Length < 1) 
     90      if (thresholdsArr.Length != classValuesArr.Length || thresholdsArr.Length < 1)
    9191        throw new ArgumentException();
    92       if (!double.IsNegativeInfinity(thresholds.First())) 
     92      if (!double.IsNegativeInfinity(thresholds.First()))
    9393        throw new ArgumentException();
    9494
     
    107107    }
    108108
    109     public IEnumerable<double> GetEstimatedValues(Dataset dataset, IEnumerable<int> rows) {
     109    public IEnumerable<double> GetEstimatedValues(IDataset dataset, IEnumerable<int> rows) {
    110110      return Interpreter.GetSymbolicExpressionTreeValues(SymbolicExpressionTree, dataset, rows).LimitToRange(LowerEstimationLimit, UpperEstimationLimit);
    111111    }
    112112
    113     public override IEnumerable<double> GetEstimatedClassValues(Dataset dataset, IEnumerable<int> rows) {
     113    public override IEnumerable<double> GetEstimatedClassValues(IDataset dataset, IEnumerable<int> rows) {
    114114      if (!Thresholds.Any() && !ClassValues.Any()) throw new ArgumentException("No thresholds and class values were set for the current symbolic classification model.");
    115115      foreach (var x in GetEstimatedValues(dataset, rows)) {
  • trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification/3.4/SymbolicNearestNeighbourClassificationModel.cs

    r12012 r12509  
    6666    }
    6767
    68     public override IEnumerable<double> GetEstimatedClassValues(Dataset dataset, IEnumerable<int> rows) {
     68    public override IEnumerable<double> GetEstimatedClassValues(IDataset dataset, IEnumerable<int> rows) {
    6969      var estimatedValues = Interpreter.GetSymbolicExpressionTreeValues(SymbolicExpressionTree, dataset, rows)
    7070                                       .LimitToRange(LowerEstimationLimit, UpperEstimationLimit);
Note: See TracChangeset for help on using the changeset viewer.