Ignore:
Timestamp:
08/19/11 11:12:25 (11 years ago)
Author:
mkommend
Message:

#1592: Implemented new estimated class values view for ClassificationEnsembleSolutions.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/Regression/RegressionEnsembleProblemData.cs

    r6666 r6672  
    2121
    2222using System.Collections.Generic;
    23 using System.Linq;
    2423using HeuristicLab.Common;
    2524using HeuristicLab.Core;
     
    3332  public sealed class RegressionEnsembleProblemData : RegressionProblemData {
    3433
    35     public override IEnumerable<int> TrainingIndizes {
    36       get {
    37         return Enumerable.Range(TrainingPartition.Start, TrainingPartition.End - TrainingPartition.Start);
    38       }
     34    public override bool IsTrainingSample(int index) {
     35      return index >= 0 && index < Dataset.Rows &&
     36             TrainingPartition.Start <= index && index < TrainingPartition.End;
    3937    }
    4038
    41     public override IEnumerable<int> TestIndizes {
    42       get {
    43         return Enumerable.Range(TestPartition.Start, TestPartition.End - TestPartition.Start);
    44       }
     39    public override bool IsTestSample(int index) {
     40      return index >= 0 && index < Dataset.Rows &&
     41             TestPartition.Start <= index && index < TestPartition.End;
    4542    }
    4643
    47     private static RegressionEnsembleProblemData emptyProblemData;
     44    private static readonly RegressionEnsembleProblemData emptyProblemData;
    4845    public new static RegressionEnsembleProblemData EmptyProblemData {
    4946      get { return emptyProblemData; }
Note: See TracChangeset for help on using the changeset viewer.