Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/AccuracyEvaluator.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/AccuracyEvaluator.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/AccuracyEvaluator.cs	(revision 482)
@@ -35,7 +35,8 @@
     private double[] classesArr;
     private double[] thresholds;
+    private DoubleData accuracy;
     public override string Description {
       get {
-        return @"TASK";
+        return @"Calculates the total accuracy of the model (ratio of correctly classified instances to total number of instances) given a model and the list of possible target class values.";
       }
     }
@@ -43,8 +44,15 @@
     public AccuracyEvaluator()
       : base() {
+      AddVariableInfo(new VariableInfo("Accuracy", "The total accuracy of the model (ratio of correctly classified instances to total number of instances)", typeof(DoubleData), VariableKind.New));
       AddVariableInfo(new VariableInfo("TargetClassValues", "The original class values of target variable (for instance negative=0 and positive=1).", typeof(ItemList<DoubleData>), VariableKind.In));
     }
 
     public override IOperation Apply(IScope scope) {
+      accuracy = GetVariableValue<DoubleData>("Accuracy", scope, false, false);
+      if(accuracy == null) {
+        accuracy = new DoubleData();
+        scope.AddVariable(new HeuristicLab.Core.Variable(scope.TranslateName("Accuracy"), accuracy));
+      }
+
       ItemList<DoubleData> classes = GetVariableValue<ItemList<DoubleData>>("TargetClassValues", scope, true);
       classesArr = new double[classes.Count];
@@ -59,6 +67,6 @@
     }
 
-    public override double Evaluate(int start, int end) {
-      int nSamples = end-start;
+    public override void Evaluate(int start, int end) {
+      int nSamples = end - start;
       int nCorrect = 0;
       for(int sample = start; sample < end; sample++) {
@@ -70,5 +78,5 @@
         if(est < thresholds[0]) estClass = classesArr[0];
         // if estimation is larger (or equal) than the largest threshold value -> estimated class is the upper class
-        else if(est >= thresholds[thresholds.Length - 1]) estClass = classesArr[classesArr.Length - 1];  
+        else if(est >= thresholds[thresholds.Length - 1]) estClass = classesArr[classesArr.Length - 1];
         else {
           // otherwise the estimated class is the class which upper threshold is larger than the estimated value
@@ -82,5 +90,5 @@
         if(Math.Abs(estClass - origClass) < EPSILON) nCorrect++;
       }
-      return  nCorrect / (double)nSamples;
+      accuracy.Data = nCorrect / (double)nSamples;
     }
   }
Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/ClassificationMeanSquaredErrorEvaluator.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/ClassificationMeanSquaredErrorEvaluator.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/ClassificationMeanSquaredErrorEvaluator.cs	(revision 482)
@@ -31,5 +31,5 @@
 
 namespace HeuristicLab.StructureIdentification {
-  public class ClassificationMeanSquaredErrorEvaluator : GPEvaluatorBase {
+  public class ClassificationMeanSquaredErrorEvaluator : MeanSquaredErrorEvaluator {
     private const double EPSILON = 1.0E-6;
     private double[] classesArr;
@@ -54,6 +54,5 @@
     }
 
-    public override double Evaluate(int start, int end) {
-
+    public override void Evaluate(int start, int end) {
       double errorsSquaredSum = 0;
       for(int sample = start; sample < end; sample++) {
@@ -79,5 +78,5 @@
         errorsSquaredSum = double.MaxValue;
       }
-      return errorsSquaredSum;
+      mse.Data = errorsSquaredSum;
     }
 
Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/CoefficientOfDeterminationEvaluator.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/CoefficientOfDeterminationEvaluator.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/CoefficientOfDeterminationEvaluator.cs	(revision 482)
@@ -32,4 +32,5 @@
 namespace HeuristicLab.StructureIdentification {
   public class CoefficientOfDeterminationEvaluator : GPEvaluatorBase {
+    private DoubleData r2;
     public override string Description {
       get {
@@ -41,7 +42,18 @@
     public CoefficientOfDeterminationEvaluator()
       : base() {
+      AddVariableInfo(new VariableInfo("R2", "The coefficient of determination of the model", typeof(DoubleData), VariableKind.New));
     }
 
-    public override double Evaluate(int start, int end) {
+    public override IOperation Apply(IScope scope) {
+      r2 = GetVariableValue<DoubleData>("R2", scope, false, false);
+      if(r2 == null) {
+        r2 = new DoubleData();
+        scope.AddVariable(new HeuristicLab.Core.Variable(scope.TranslateName("R2"), r2));
+      }
+
+      return base.Apply(scope);
+    }
+
+    public override void Evaluate(int start, int end) {
       double errorsSquaredSum = 0.0;
       double originalDeviationTotalSumOfSquares = 0.0;
@@ -60,9 +72,9 @@
 
       double quality = 1 - errorsSquaredSum / originalDeviationTotalSumOfSquares;
-      if(quality > 1) 
+      if(quality > 1)
         throw new InvalidProgramException();
-      if(double.IsNaN(quality) || double.IsInfinity(quality)) 
+      if(double.IsNaN(quality) || double.IsInfinity(quality))
         quality = double.MaxValue;
-      return quality;
+      r2.Data = quality;
     }
   }
Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/EarlyStoppingMeanSquaredErrorEvaluator.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/EarlyStoppingMeanSquaredErrorEvaluator.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/EarlyStoppingMeanSquaredErrorEvaluator.cs	(revision 482)
@@ -52,5 +52,5 @@
 
     // evaluates the function-tree for the given target-variable and the whole dataset and returns the MSE
-    public override double Evaluate(int start, int end) {
+    public override void Evaluate(int start, int end) {
       double errorsSquaredSum = 0;
       int rows = end - start;
@@ -65,5 +65,6 @@
         // check the limit and stop as soon as we hit the limit
         if(errorsSquaredSum / rows >= qualityLimit) {
-          return errorsSquaredSum / (sample - start + 1); // return estimated MSE (when the remaining errors are on average the same)
+          mse.Data = errorsSquaredSum / (sample - start + 1); // return estimated MSE (when the remaining errors are on average the same)
+          return;
         }
       }
@@ -72,5 +73,5 @@
         errorsSquaredSum = double.MaxValue;
       }
-      return errorsSquaredSum;
+      mse.Data = errorsSquaredSum;
     }
   }
Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/GPEvaluatorBase.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/GPEvaluatorBase.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/GPEvaluatorBase.cs	(revision 482)
@@ -34,6 +34,6 @@
     private IEvaluator evaluator;
     private int targetVariable;
-    private int trainingStart;
-    private int trainingEnd;
+    private int start;
+    private int end;
     private bool useEstimatedValues;
     private double[] backupValues;
@@ -55,8 +55,7 @@
       AddVariableInfo(new VariableInfo("PunishmentFactor", "Punishment factor for invalid estimations", typeof(DoubleData), VariableKind.In));
       AddVariableInfo(new VariableInfo("TotalEvaluatedNodes", "Number of evaluated nodes", typeof(DoubleData), VariableKind.In | VariableKind.Out));
-      AddVariableInfo(new VariableInfo("TrainingSamplesStart", "Start index of training samples in dataset", typeof(IntData), VariableKind.In));
-      AddVariableInfo(new VariableInfo("TrainingSamplesEnd", "End index of training samples in dataset", typeof(IntData), VariableKind.In));
+      AddVariableInfo(new VariableInfo("SamplesStart", "Start index of samples in dataset to evaluate", typeof(IntData), VariableKind.In));
+      AddVariableInfo(new VariableInfo("SamplesEnd", "End index of samples in dataset to evaluate", typeof(IntData), VariableKind.In));
       AddVariableInfo(new VariableInfo("UseEstimatedTargetValue", "Wether to use the original (measured) or the estimated (calculated) value for the targat variable when doing autoregressive modelling", typeof(BoolData), VariableKind.In));
-      AddVariableInfo(new VariableInfo("Quality", "The evaluated quality of the model", typeof(DoubleData), VariableKind.New));
     }
 
@@ -69,19 +68,19 @@
       treeSize = scope.GetVariableValue<IntData>("TreeSize", false).Data;
       totalEvaluatedNodes = scope.GetVariableValue<DoubleData>("TotalEvaluatedNodes", true).Data;
-      int trainingStart = GetVariableValue<IntData>("TrainingSamplesStart", scope, true).Data;
-      int trainingEnd = GetVariableValue<IntData>("TrainingSamplesEnd", scope, true).Data;
+      int start = GetVariableValue<IntData>("SamplesStart", scope, true).Data;
+      int end = GetVariableValue<IntData>("SamplesEnd", scope, true).Data;
       useEstimatedValues = GetVariableValue<BoolData>("UseEstimatedTargetValue", scope, true).Data;
       // prepare for autoregressive modelling by saving the original values of the target-variable to a backup array
       if(useEstimatedValues && 
-        (backupValues == null || trainingStart!=this.trainingStart || trainingEnd!=this.trainingEnd)) {
-        this.trainingStart = trainingStart;
-        this.trainingEnd = trainingEnd;
-        backupValues = new double[trainingEnd - trainingStart];
-        for(int i = trainingStart; i < trainingEnd; i++) {
-          backupValues[i - trainingStart] = dataset.GetValue(i, targetVariable);
+        (backupValues == null || start!=this.start || end!=this.end)) {
+        this.start = start;
+        this.end = end;
+        backupValues = new double[end - start];
+        for(int i = start; i < end; i++) {
+          backupValues[i - start] = dataset.GetValue(i, targetVariable);
         }
       }
       // get the mean of the values of the target variable to determin the max and min bounds of the estimated value
-      targetMean = dataset.GetMean(targetVariable, trainingStart, trainingEnd);
+      targetMean = dataset.GetMean(targetVariable, start, end);
       estimatedValueMin = targetMean - maximumPunishment;
       estimatedValueMax = targetMean + maximumPunishment;
@@ -92,18 +91,11 @@
       evaluatedSamples = 0;
 
-      // calculate the quality measure
-      double result = Evaluate(trainingStart, trainingEnd);
+      Evaluate(start, end);
 
       // restore the values of the target variable from the backup array if necessary
-      if(useEstimatedValues) RestoreDataset(dataset, targetVariable, trainingStart, trainingEnd);
+      if(useEstimatedValues) RestoreDataset(dataset, targetVariable, start, end);
       // update the value of total evaluated nodes
       scope.GetVariableValue<DoubleData>("TotalEvaluatedNodes", true).Data = totalEvaluatedNodes + treeSize * evaluatedSamples;
       // write the calculate quality value
-      DoubleData quality = GetVariableValue<DoubleData>("Quality", scope, false, false);
-      if(quality == null) {
-        scope.AddVariable(new HeuristicLab.Core.Variable(scope.TranslateName("Quality"), new DoubleData(result)));
-      } else {
-        quality.Data = result;
-      }
       return null;
     }
@@ -115,5 +107,5 @@
     }
 
-    public abstract double Evaluate(int start, int end);
+    public abstract void Evaluate(int start, int end);
 
     public void SetOriginalValue(int sample, double value) {
Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MCCEvaluator.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MCCEvaluator.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MCCEvaluator.cs	(revision 482)
@@ -35,7 +35,8 @@
     private double[] original = new double[1];
     private double[] estimated = new double[1];
+    private DoubleData mcc;
     public override string Description {
       get {
-        return @"TASK";
+        return @"Calculates the matthews correlation coefficient for a given model and class separation threshold";
       }
     }
@@ -43,12 +44,18 @@
       : base() {
       AddVariableInfo(new VariableInfo("ClassSeparation", "The value of separation between negative and positive target classification values (for instance 0.5 if negative=0 and positive=1).", typeof(DoubleData), VariableKind.In));
+      AddVariableInfo(new VariableInfo("MCC", "The matthews correlation coefficient of the model", typeof(DoubleData), VariableKind.New));
     }
 
     public override IOperation Apply(IScope scope) {
+      mcc = GetVariableValue<DoubleData>("MCC", scope, false, false);
+      if(mcc == null) {
+        mcc = new DoubleData();
+        scope.AddVariable(new HeuristicLab.Core.Variable(scope.TranslateName("MCC"), mcc));
+      }
       limit = GetVariableValue<DoubleData>("ClassSeparation", scope, true).Data;
       return base.Apply(scope);
     }
 
-    public override double Evaluate(int start, int end) {
+    public override void Evaluate(int start, int end) {
       int nSamples = end - start;
       if(estimated.Length != nSamples) {
@@ -85,5 +92,5 @@
         }
       }
-      return best_mcc;
+      this.mcc.Data = best_mcc;
     }
   }
Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MeanAbsolutePercentageErrorEvaluator.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MeanAbsolutePercentageErrorEvaluator.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MeanAbsolutePercentageErrorEvaluator.cs	(revision 482)
@@ -32,4 +32,5 @@
 namespace HeuristicLab.StructureIdentification {
   public class MeanAbsolutePercentageErrorEvaluator : GPEvaluatorBase {
+    private DoubleData mape;
     public override string Description {
       get {
@@ -41,7 +42,18 @@
     public MeanAbsolutePercentageErrorEvaluator()
       : base() {
+      AddVariableInfo(new VariableInfo("MAPE", "The mean absolute percentage error of the model", typeof(DoubleData), VariableKind.New));
     }
 
-    public override double Evaluate(int start, int end) {
+    public override IOperation Apply(IScope scope) {
+      mape = GetVariableValue<DoubleData>("MAPE", scope, false, false);
+      if(mape == null) {
+        mape = new DoubleData();
+        scope.AddVariable(new HeuristicLab.Core.Variable(scope.TranslateName("MAPE"), mape));
+      }
+
+      return base.Apply(scope);
+    }
+
+    public override void Evaluate(int start, int end) {
       double errorsSum = 0.0;
       for(int sample = start; sample < end; sample++) {
@@ -57,5 +69,5 @@
       if(double.IsNaN(quality) || double.IsInfinity(quality))
         quality = double.MaxValue;
-      return quality;
+      mape.Data = quality;
     }
   }
Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MeanSquaredErrorEvaluator.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MeanSquaredErrorEvaluator.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MeanSquaredErrorEvaluator.cs	(revision 482)
@@ -32,4 +32,5 @@
 namespace HeuristicLab.StructureIdentification {
   public class MeanSquaredErrorEvaluator : GPEvaluatorBase {
+    protected DoubleData mse;
     public override string Description {
       get {
@@ -41,7 +42,18 @@
     public MeanSquaredErrorEvaluator()
       : base() {
+      AddVariableInfo(new VariableInfo("MSE", "The mean squared error of the model", typeof(DoubleData), VariableKind.New));
     }
 
-    public override double Evaluate(int start, int end) {
+    public override IOperation Apply(IScope scope) {
+      mse = GetVariableValue<DoubleData>("MSE", scope, false, false);
+      if(mse == null) {
+        mse = new DoubleData();
+        scope.AddVariable(new HeuristicLab.Core.Variable(scope.TranslateName("MSE"), mse));
+      }
+
+      return base.Apply(scope);
+    }
+
+    public override void Evaluate(int start, int end) {
       double errorsSquaredSum = 0;
       for(int sample = start; sample < end; sample++) {
@@ -59,5 +71,5 @@
         errorsSquaredSum = double.MaxValue;
       }
-      return errorsSquaredSum;
+      mse.Data = errorsSquaredSum;
     }
   }
Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/SimpleEvaluator.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/SimpleEvaluator.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/SimpleEvaluator.cs	(revision 482)
@@ -52,5 +52,5 @@
     }
 
-    public override double Evaluate(int start, int end) {
+    public override void Evaluate(int start, int end) {
       for(int sample = start; sample < end; sample++) {
         ItemList row = new ItemList();
@@ -62,5 +62,4 @@
         values.Add(row);
       }
-      return double.NaN;
     }
   }
Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/TheilInequalityCoefficientEvaluator.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/TheilInequalityCoefficientEvaluator.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/TheilInequalityCoefficientEvaluator.cs	(revision 482)
@@ -33,4 +33,5 @@
   public class TheilInequalityCoefficientEvaluator : GPEvaluatorBase {
     private bool differential;
+    private DoubleData theilInequaliy;
     public override string Description {
       get {
@@ -43,12 +44,20 @@
       : base() {
       AddVariableInfo(new VariableInfo("Differential", "Wether to calculate the coefficient for the predicted change vs. original change or for the absolute prediction vs. original value", typeof(BoolData), VariableKind.In));
+      AddVariableInfo(new VariableInfo("TheilInequalityCoefficient", "Theil's inequality coefficient of the model", typeof(DoubleData), VariableKind.New));
+
     }
 
     public override IOperation Apply(IScope scope) {
       differential = GetVariableValue<BoolData>("Differential", scope, true).Data;
+      theilInequaliy = GetVariableValue<DoubleData>("TheilInequalityCoefficient", scope, false, false);
+      if(theilInequaliy == null) {
+        theilInequaliy = new DoubleData();
+        scope.AddVariable(new HeuristicLab.Core.Variable(scope.TranslateName("TheilInequalityCoefficient"), theilInequaliy));
+      }
+
       return base.Apply(scope);
     }
 
-    public override double Evaluate(int start, int end) {
+    public override void Evaluate(int start, int end) {
       double errorsSquaredSum = 0.0;
       double estimatedSquaredSum = 0.0;
@@ -59,5 +68,5 @@
         double estimatedChange = GetEstimatedValue(sample) - prevValue;
         double originalChange = GetOriginalValue(sample) - prevValue;
-        SetOriginalValue(sample, estimatedChange+prevValue);
+        SetOriginalValue(sample, estimatedChange + prevValue);
         if(!double.IsNaN(originalChange) && !double.IsInfinity(originalChange)) {
           double error = estimatedChange - originalChange;
@@ -71,5 +80,5 @@
       if(double.IsNaN(quality) || double.IsInfinity(quality))
         quality = double.MaxValue;
-      return quality;
+      theilInequaliy.Data = quality;
     }
   }
Index: /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/VarianceAccountedForEvaluator.cs
===================================================================
--- /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/VarianceAccountedForEvaluator.cs	(revision 481)
+++ /trunk/sources/HeuristicLab.StructureIdentification/Evaluation/VarianceAccountedForEvaluator.cs	(revision 482)
@@ -32,4 +32,5 @@
 namespace HeuristicLab.StructureIdentification {
   public class VarianceAccountedForEvaluator : GPEvaluatorBase {
+    private DoubleData vaf;
     public override string Description {
       get {
@@ -50,8 +51,19 @@
     public VarianceAccountedForEvaluator()
       : base() {
+      AddVariableInfo(new VariableInfo("VAF", "The variance-accounted-for quality of the model", typeof(DoubleData), VariableKind.New));
+
     }
 
+    public override IOperation Apply(IScope scope) {
+      vaf = GetVariableValue<DoubleData>("VAF", scope, false, false);
+      if(vaf == null) {
+        vaf = new DoubleData();
+        scope.AddVariable(new HeuristicLab.Core.Variable(scope.TranslateName("VAF"), vaf));
+      }
 
-    public override double Evaluate(int start, int end) {
+      return base.Apply(scope);
+    }
+
+    public override void Evaluate(int start, int end) {
       int nSamples = end - start;
       double[] errors = new double[nSamples];
@@ -73,5 +85,5 @@
         quality = double.MaxValue;
       }
-      return quality;
+      vaf.Data = quality;
     }
   }
