Changeset 9386 for branches/sluengo/HeuristicLab.Problems.TradeRules/Evaluator/EvaluatorTradeRules.cs
- Timestamp:
- 04/20/13 14:08:49 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/sluengo/HeuristicLab.Problems.TradeRules/Evaluator/EvaluatorTradeRules.cs
r9325 r9386 44 44 double quality = Calculate((ITradeRulesExpresionTree) SymbolicDataAnalysisTreeInterpreterParameter.ActualValue, solution, EstimationLimitsParameter.ActualValue.Lower, EstimationLimitsParameter.ActualValue.Upper, ProblemDataParameter.ActualValue, rows); 45 45 QualityParameter.ActualValue = new DoubleValue(quality); 46 ITradeRulesExpresionTree interpreter = (ITradeRulesExpresionTree)SymbolicDataAnalysisTreeInterpreterParameter.ActualValue;47 interpreter.clearVariables();48 46 return base.Apply(); 49 47 } … … 52 50 { 53 51 interpreter.setInitialTraining(initialTraining); 54 interpreter.setInitialTest( initialTest);52 interpreter.setInitialTest(rows.ToArray()[0]); 55 53 IEnumerable<double> estimatedValues = interpreter.GetSymbolicExpressionTreeValues(solution, problemData.Dataset, rows); 54 interpreter.clearVariables(); 55 double tradingCash = OnlineTradeRulesCalculator.Calculate(estimatedValues, problemData, rows); 56 56 57 double tradingCash = OnlineTradeRulesCalculator.Calculate(estimatedValues, problemData, problemData.TrainingIndices);58 59 57 return tradingCash; 60 58 } … … 69 67 EstimationLimitsParameter.ExecutionContext = null; 70 68 71 72 69 return r2; 73 70 }
Note: See TracChangeset
for help on using the changeset viewer.