Changeset 1796 for trunk/sources/HeuristicLab.GP.StructureIdentification/3.3/Evaluators/VarianceAccountedForEvaluator.cs
- Timestamp:
- 05/14/09 13:46:57 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.GP.StructureIdentification/3.3/Evaluators/VarianceAccountedForEvaluator.cs
r712 r1796 53 53 } 54 54 55 public override void Evaluate(IScope scope, BakedTreeEvaluator evaluator, Dataset dataset, int targetVariable, int start, int end, bool updateTargetValues) {55 public override void Evaluate(IScope scope, ITreeEvaluator evaluator, IFunctionTree tree, Dataset dataset, int targetVariable, int start, int end, bool updateTargetValues) { 56 56 int nSamples = end - start; 57 57 double[] errors = new double[nSamples]; 58 58 double[] originalTargetVariableValues = new double[nSamples]; 59 59 for (int sample = start; sample < end; sample++) { 60 double estimated = evaluator.Evaluate( sample);60 double estimated = evaluator.Evaluate(tree, sample); 61 61 double original = dataset.GetValue(sample, targetVariable); 62 62 if (updateTargetValues) { … … 66 66 errors[sample - start] = original - estimated; 67 67 originalTargetVariableValues[sample - start] = original; 68 } else { 69 errors[sample - start] = double.NaN; 70 originalTargetVariableValues[sample - start] = double.NaN; 68 71 } 69 72 }
Note: See TracChangeset
for help on using the changeset viewer.