Changeset 6784 for branches/GP.Grammar.Editor/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionErrorCharacteristicsCurveView.cs
- Timestamp:
- 09/16/11 12:00:36 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/GP.Grammar.Editor/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionErrorCharacteristicsCurveView.cs
r6647 r6784 139 139 if (residuals[i] > chart.ChartAreas[0].AxisX.Maximum) { 140 140 point.XValue = chart.ChartAreas[0].AxisX.Maximum; 141 point.YValues[0] = ((double)i - 1) / residuals.Count;141 point.YValues[0] = ((double)i) / residuals.Count; 142 142 point.ToolTip = "Error: " + point.XValue + "\n" + "Samples: " + point.YValues[0]; 143 143 series.Points.Add(point); … … 146 146 147 147 point.XValue = residuals[i]; 148 point.YValues[0] = ((double)i ) / residuals.Count;148 point.YValues[0] = ((double)i+1) / residuals.Count; 149 149 point.ToolTip = "Error: " + point.XValue + "\n" + "Samples: " + point.YValues[0]; 150 150 series.Points.Add(point); … … 164 164 switch (cmbSamples.SelectedItem.ToString()) { 165 165 case TrainingSamples: 166 originalValues = ProblemData.Dataset.Get EnumeratedVariableValues(ProblemData.TargetVariable, ProblemData.TrainingIndizes);166 originalValues = ProblemData.Dataset.GetDoubleValues(ProblemData.TargetVariable, ProblemData.TrainingIndizes); 167 167 break; 168 168 case TestSamples: 169 originalValues = ProblemData.Dataset.Get EnumeratedVariableValues(ProblemData.TargetVariable, ProblemData.TestIndizes);169 originalValues = ProblemData.Dataset.GetDoubleValues(ProblemData.TargetVariable, ProblemData.TestIndizes); 170 170 break; 171 171 case AllSamples: 172 originalValues = ProblemData.Dataset.Get EnumeratedVariableValues(ProblemData.TargetVariable);172 originalValues = ProblemData.Dataset.GetDoubleValues(ProblemData.TargetVariable); 173 173 break; 174 174 default: … … 197 197 198 198 protected IEnumerable<double> GetMeanModelEstimatedValues(IEnumerable<double> originalValues) { 199 double averageTrainingTarget = ProblemData.Dataset.Get EnumeratedVariableValues(ProblemData.TargetVariable, ProblemData.TrainingIndizes).Average();199 double averageTrainingTarget = ProblemData.Dataset.GetDoubleValues(ProblemData.TargetVariable, ProblemData.TrainingIndizes).Average(); 200 200 return Enumerable.Repeat(averageTrainingTarget, originalValues.Count()); 201 201 }
Note: See TracChangeset
for help on using the changeset viewer.