Index: trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/SymbolicDataAnalysisExpressionTreeILEmittingInterpreter.cs
===================================================================
--- trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/SymbolicDataAnalysisExpressionTreeILEmittingInterpreter.cs	(revision 6735)
+++ trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/SymbolicDataAnalysisExpressionTreeILEmittingInterpreter.cs	(revision 6740)
@@ -26,8 +26,8 @@
 using HeuristicLab.Common;
 using HeuristicLab.Core;
+using HeuristicLab.Data;
 using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding;
+using HeuristicLab.Parameters;
 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
-using HeuristicLab.Data;
-using HeuristicLab.Parameters;
 
 namespace HeuristicLab.Problems.DataAnalysis.Symbolic {
@@ -224,13 +224,13 @@
         if (instr.opCode == OpCodes.Variable) {
           var variableTreeNode = instr.dynamicNode as VariableTreeNode;
-          instr.iArg0 = (ushort)dataset.GetVariableIndex(variableTreeNode.VariableName);
+          instr.iArg0 = dataset.GetReadOnlyDoubleValues(variableTreeNode.VariableName);
           code[i] = instr;
         } else if (instr.opCode == OpCodes.LagVariable) {
           var variableTreeNode = instr.dynamicNode as LaggedVariableTreeNode;
-          instr.iArg0 = (ushort)dataset.GetVariableIndex(variableTreeNode.VariableName);
+          instr.iArg0 = dataset.GetReadOnlyDoubleValues(variableTreeNode.VariableName);
           code[i] = instr;
         } else if (instr.opCode == OpCodes.VariableCondition) {
           var variableConditionTreeNode = instr.dynamicNode as VariableConditionTreeNode;
-          instr.iArg0 = (ushort)dataset.GetVariableIndex(variableConditionTreeNode.VariableName);
+          instr.iArg0 = dataset.GetReadOnlyDoubleValues(variableConditionTreeNode.VariableName);
         } else if (instr.opCode == OpCodes.Call) {
           necessaryArgStackSize += instr.nArguments + 1;
@@ -468,13 +468,13 @@
           }
         case OpCodes.Variable: {
-            VariableTreeNode varNode = (VariableTreeNode)currentInstr.dynamicNode;
-            il.Emit(System.Reflection.Emit.OpCodes.Ldarg_0); // load dataset
-            il.Emit(System.Reflection.Emit.OpCodes.Ldc_I4, 0); // sampleOffset
-            il.Emit(System.Reflection.Emit.OpCodes.Ldarg_1); // sampleIndex
-            il.Emit(System.Reflection.Emit.OpCodes.Add); // row = sampleIndex + sampleOffset
-            il.Emit(System.Reflection.Emit.OpCodes.Ldc_I4, currentInstr.iArg0); // load var
-            il.Emit(System.Reflection.Emit.OpCodes.Call, datasetGetValue); // dataset.GetValue
-            il.Emit(System.Reflection.Emit.OpCodes.Ldc_R8, varNode.Weight); // load weight
-            il.Emit(System.Reflection.Emit.OpCodes.Mul);
+            //VariableTreeNode varNode = (VariableTreeNode)currentInstr.dynamicNode;
+            //il.Emit(System.Reflection.Emit.OpCodes.Ldarg_0); // load dataset
+            //il.Emit(System.Reflection.Emit.OpCodes.Ldc_I4, 0); // sampleOffset
+            //il.Emit(System.Reflection.Emit.OpCodes.Ldarg_1); // sampleIndex
+            //il.Emit(System.Reflection.Emit.OpCodes.Add); // row = sampleIndex + sampleOffset
+            //il.Emit(System.Reflection.Emit.OpCodes.Ldc_I4, currentInstr.iArg0); // load var
+            //il.Emit(System.Reflection.Emit.OpCodes.Call, datasetGetValue); // dataset.GetValue
+            //il.Emit(System.Reflection.Emit.OpCodes.Ldc_R8, varNode.Weight); // load weight
+            //il.Emit(System.Reflection.Emit.OpCodes.Mul);
             return;
           }
Index: trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/SymbolicDataAnalysisExpressionTreeInterpreter.cs
===================================================================
--- trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/SymbolicDataAnalysisExpressionTreeInterpreter.cs	(revision 6735)
+++ trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/SymbolicDataAnalysisExpressionTreeInterpreter.cs	(revision 6740)
@@ -24,8 +24,8 @@
 using HeuristicLab.Common;
 using HeuristicLab.Core;
+using HeuristicLab.Data;
 using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding;
+using HeuristicLab.Parameters;
 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
-using HeuristicLab.Data;
-using HeuristicLab.Parameters;
 
 namespace HeuristicLab.Problems.DataAnalysis.Symbolic {
@@ -208,13 +208,13 @@
         if (instr.opCode == OpCodes.Variable) {
           var variableTreeNode = instr.dynamicNode as VariableTreeNode;
-          instr.iArg0 = (ushort)dataset.GetVariableIndex(variableTreeNode.VariableName);
+          instr.iArg0 = dataset.GetReadOnlyDoubleValues(variableTreeNode.VariableName);
           code[i] = instr;
         } else if (instr.opCode == OpCodes.LagVariable) {
-          var variableTreeNode = instr.dynamicNode as LaggedVariableTreeNode;
-          instr.iArg0 = (ushort)dataset.GetVariableIndex(variableTreeNode.VariableName);
+          var laggedVariableTreeNode = instr.dynamicNode as LaggedVariableTreeNode;
+          instr.iArg0 = dataset.GetReadOnlyDoubleValues(laggedVariableTreeNode.VariableName);
           code[i] = instr;
         } else if (instr.opCode == OpCodes.VariableCondition) {
           var variableConditionTreeNode = instr.dynamicNode as VariableConditionTreeNode;
-          instr.iArg0 = (ushort)dataset.GetVariableIndex(variableConditionTreeNode.VariableName);
+          instr.iArg0 = dataset.GetReadOnlyDoubleValues(variableConditionTreeNode.VariableName);
         } else if (instr.opCode == OpCodes.Call) {
           necessaryArgStackSize += instr.nArguments + 1;
@@ -390,5 +390,5 @@
             int savedPc = state.ProgramCounter;
             // set pc to start of function  
-            state.ProgramCounter = currentInstr.iArg0;
+            state.ProgramCounter = (ushort)currentInstr.iArg0;
             // evaluate the function
             double v = Evaluate(dataset, ref row, state);
@@ -402,18 +402,18 @@
           }
         case OpCodes.Arg: {
-            return state.GetStackFrameValue(currentInstr.iArg0);
+            return state.GetStackFrameValue((ushort)currentInstr.iArg0);
           }
         case OpCodes.Variable: {
             if (row < 0 || row >= dataset.Rows)
               return double.NaN;
-            var variableTreeNode = currentInstr.dynamicNode as VariableTreeNode;
-            return dataset[row, currentInstr.iArg0] * variableTreeNode.Weight;
+            var variableTreeNode = (VariableTreeNode)currentInstr.dynamicNode;
+            return ((IList<double>)currentInstr.iArg0)[row] * variableTreeNode.Weight;
           }
         case OpCodes.LagVariable: {
-            var laggedVariableTreeNode = currentInstr.dynamicNode as LaggedVariableTreeNode;
+            var laggedVariableTreeNode = (LaggedVariableTreeNode)currentInstr.dynamicNode;
             int actualRow = row + laggedVariableTreeNode.Lag;
             if (actualRow < 0 || actualRow >= dataset.Rows)
               return double.NaN;
-            return dataset[actualRow, currentInstr.iArg0] * laggedVariableTreeNode.Weight;
+            return ((IList<double>)currentInstr.iArg0)[row] * laggedVariableTreeNode.Weight;
           }
         case OpCodes.Constant: {
@@ -428,5 +428,5 @@
               return double.NaN;
             var variableConditionTreeNode = (VariableConditionTreeNode)currentInstr.dynamicNode;
-            double variableValue = dataset[row, currentInstr.iArg0];
+            double variableValue = ((IList<double>)currentInstr.iArg0)[row];
             double x = variableValue - variableConditionTreeNode.Threshold;
             double p = 1 / (1 + Math.Exp(-variableConditionTreeNode.Slope * x));
