- Timestamp:
- 10/29/15 18:29:17 (9 years ago)
- Location:
- branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views
- Files:
-
- 86 edited
- 3 copied
Legend:
- Unmodified
- Added
- Removed
-
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views
- Property svn:mergeinfo changed
-
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationEnsembleSolutionEstimatedClassValuesView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationEnsembleSolutionEstimatedClassValuesView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationEnsembleSolutionModelView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationEnsembleSolutionModelView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationFeatureCorrelationView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationFeatureCorrelationView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationSolutionConfusionMatrixView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationSolutionConfusionMatrixView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationSolutionEstimatedClassValuesView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationSolutionEstimatedClassValuesView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationTimeframeFeatureCorrelationView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationTimeframeFeatureCorrelationView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/DiscriminantFunctionClassificationModelView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/DiscriminantFunctionClassificationModelView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/DiscriminantFunctionClassificationRocCurvesView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/DiscriminantFunctionClassificationRocCurvesView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/DiscriminantFunctionClassificationSolutionEstimatedClassValuesView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/DiscriminantFunctionClassificationSolutionEstimatedClassValuesView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/DiscriminantFunctionClassificationSolutionThresholdView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/DiscriminantFunctionClassificationSolutionThresholdView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Clustering/ClusteringSolutionEstimatedClusterView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Clustering/ClusteringSolutionEstimatedClusterView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Clustering/ClusteringSolutionVisualizationView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Clustering/ClusteringSolutionVisualizationView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 81 81 82 82 int idx = 0; 83 var oneDim = reduced.GetLength(1) == 1; 83 84 foreach (var r in range) { 84 rows[classes[r].Item2].Points.Add(new Point2D<double>(reduced[idx, 0], reduced[idx, 1])); 85 Point2D<double> point; 86 point = oneDim ? new Point2D<double>(reduced[idx, 0], 0.0) : new Point2D<double>(reduced[idx, 0], reduced[idx, 1]); 87 rows[classes[r].Item2].Points.Add(point); 85 88 idx++; 86 89 } … … 89 92 } 90 93 91 private static double[,] PCAReduce( Dataset dataset, IEnumerable<int> rows, IEnumerable<string> variables) {94 private static double[,] PCAReduce(IDataset dataset, IEnumerable<int> rows, IEnumerable<string> variables) { 92 95 var instances = rows.ToArray(); 93 96 var attributes = variables.ToArray(); … … 106 109 alglib.pcabuildbasis(data, instances.Length, attributes.Length, out info, out variances, out matrix); 107 110 108 var result = new double[instances.Length, 2];111 var result = new double[instances.Length, matrix.GetLength(1)]; 109 112 int r = 0; 110 113 foreach (var inst in instances) { -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/DataAnalysisSolutionEvaluationView.Designer.cs
r10553 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/DataAnalysisSolutionEvaluationView.cs
r10553 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/DoubleLimitView.Designer.cs
r10553 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/DoubleLimitView.cs
r10553 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/FeatureCorrelation/AbstractFeatureCorrelationView.Designer.cs
r10556 r13082 2 2 3 3 /* HeuristicLab 4 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)4 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 5 5 * 6 6 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/FeatureCorrelation/AbstractFeatureCorrelationView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 48 48 protected AbstractFeatureCorrelationView() { 49 49 InitializeComponent(); 50 dataView.FormatPattern = "0.000"; 50 51 fcc = new FeatureCorrelationCalculator(); 51 52 var calculators = ApplicationManager.Manager.GetInstances<IDependencyCalculator>(); … … 57 58 partitionComboBox.DataSource = Partitions; 58 59 partitionComboBox.SelectedItem = TRAININGSAMPLES; 60 progressPanel.Visible = false; 59 61 } 60 62 … … 78 80 CalculateCorrelation(); 79 81 } else { 82 progressPanel.Visible = false; 80 83 dataView.Maximum = 0; 81 84 dataView.Minimum = 0; … … 113 116 dataView.Maximum = calc.Maximum; 114 117 dataView.Minimum = calc.Minimum; 118 115 119 dataView.Content = correlation; 116 120 dataView.Enabled = true; -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/FeatureCorrelation/FeatureCorrelationCache.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/FeatureCorrelation/FeatureCorrelationCalculator.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 72 72 } 73 73 74 private void CalculateElements( Dataset dataset, IDependencyCalculator calc, string partition, string variable = null, int frames = 0, double[,] alreadyCalculated = null) {74 private void CalculateElements(IDataset dataset, IDependencyCalculator calc, string partition, string variable = null, int frames = 0, double[,] alreadyCalculated = null) { 75 75 var indices = GetRelevantIndices(problemData, partition); 76 76 bwInfo = new BackgroundWorkerInfo { … … 117 117 118 118 BackgroundWorkerInfo bwInfo = (BackgroundWorkerInfo)e.Argument; 119 Datasetdataset = bwInfo.Dataset;119 var dataset = bwInfo.Dataset; 120 120 IEnumerable<int> indices = bwInfo.Indices; 121 121 IDependencyCalculator calc = bwInfo.Calculator; … … 156 156 157 157 BackgroundWorkerInfo bwInfo = (BackgroundWorkerInfo)e.Argument; 158 Datasetdataset = bwInfo.Dataset;158 var dataset = bwInfo.Dataset; 159 159 IEnumerable<int> indices = bwInfo.Indices; 160 160 IDependencyCalculator calc = bwInfo.Calculator; … … 255 255 256 256 private class BackgroundWorkerInfo { 257 public Dataset Dataset { get; set; }257 public IDataset Dataset { get; set; } 258 258 public IDependencyCalculator Calculator { get; set; } 259 259 public string Partition { get; set; } -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/FeatureCorrelation/FeatureCorrelationEnums.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/FeatureCorrelation/FeatureCorrelationTimeframeCache.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/FeatureCorrelation/FeatureCorrelationView.Designer.cs
r10556 r13082 2 2 3 3 /* HeuristicLab 4 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)4 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 5 5 * 6 6 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/FeatureCorrelation/FeatureCorrelationView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/FeatureCorrelation/TimeframeFeatureCorrelationView.Designer.cs
r10556 r13082 2 2 3 3 /* HeuristicLab 4 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)4 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 5 5 * 6 6 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/FeatureCorrelation/TimeframeFeatureCorrelationView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/HeuristicLab.Problems.DataAnalysis.Views-3.4.csproj
r13081 r13082 236 236 <DependentUpon>FeatureCorrelationView.cs</DependentUpon> 237 237 </Compile> 238 <Compile Include="Interfaces\IDataPreprocessorStarter.cs" /> 238 239 <Compile Include="MenuItems\ShrinkDataAnalysisRunsMenuItem.cs" /> 240 <Compile Include="ModifiableDatasetView.cs"> 241 <SubType>UserControl</SubType> 242 </Compile> 243 <Compile Include="ModifiableDatasetView.Designer.cs"> 244 <DependentUpon>ModifiableDatasetView.cs</DependentUpon> 245 </Compile> 239 246 <Compile Include="Plugin.cs" /> 240 247 <Compile Include="ProblemDataView.cs"> … … 417 424 <Project>{2E782078-FA81-4B70-B56F-74CE38DAC6C8}</Project> 418 425 <Name>HeuristicLab.Algorithms.DataAnalysis-3.4</Name> 426 </ProjectReference> 427 <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Symbolic.Regression\3.4\HeuristicLab.Problems.DataAnalysis.Symbolic.Regression-3.4.csproj"> 428 <Project>{5AC82412-911B-4FA2-A013-EDC5E3F3FCC2}</Project> 429 <Name>HeuristicLab.Problems.DataAnalysis.Symbolic.Regression-3.4</Name> 430 </ProjectReference> 431 <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Symbolic\3.4\HeuristicLab.Problems.DataAnalysis.Symbolic-3.4.csproj"> 432 <Project>{3D28463F-EC96-4D82-AFEE-38BE91A0CA00}</Project> 433 <Name>HeuristicLab.Problems.DataAnalysis.Symbolic-3.4</Name> 419 434 </ProjectReference> 420 435 <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis\3.4\HeuristicLab.Problems.DataAnalysis-3.4.csproj"> -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Interfaces/IDataAnalysisSolutionEvaluationView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Interfaces/IRegressionEnsembleSolutionEvaluationView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/MenuItems/CreateEnsembleMenuItem.cs
r10553 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 113 113 var cloner = new Cloner(); 114 114 var allResults = from r in runs 115 where r.Visible 115 116 select r.Results; 116 117 return from r in allResults 117 118 from result in r 118 let s = cloner.Clone(result.Value) as IDataAnalysisSolution 119 where s != null 119 let solution = result.Value as IDataAnalysisSolution 120 where solution != null 121 let s = (IDataAnalysisSolution)cloner.Clone(result.Value) 120 122 select new KeyValuePair<string, IDataAnalysisSolution>(result.Key, s); 121 123 } -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/MenuItems/ShrinkDataAnalysisRunsMenuItem.cs
r10553 r13082 2 2 3 3 /* HeuristicLab 4 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)4 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 5 5 * 6 6 * This file is part of HeuristicLab. … … 82 82 var variableValuesMapping = new Dictionary<ValuesType, ValuesType>(); 83 83 foreach (var problemData in view.Content.GetObjectGraphObjects(excludeStaticMembers: true).OfType<IDataAnalysisProblemData>()) { 84 var originalValues = variableValuesGetter(problemData.Dataset); 84 var dataset = problemData.Dataset as Dataset; 85 if (dataset == null) continue; 86 var originalValues = variableValuesGetter(dataset); 85 87 var matchingValues = GetEqualValues(originalValues, variableValuesMapping); 86 variableValuesSetter( problemData.Dataset, matchingValues);88 variableValuesSetter(dataset, matchingValues); 87 89 } 88 90 }; -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Plugin.cs.frame
r10553 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 26 26 27 27 namespace HeuristicLab.Problems.DataAnalysis.Views { 28 [Plugin("HeuristicLab.Problems.DataAnalysis.Views", "Provides views for base classes for data analysis tasks.", "3.4. 5.$WCREV$")]28 [Plugin("HeuristicLab.Problems.DataAnalysis.Views", "Provides views for base classes for data analysis tasks.", "3.4.8.$WCREV$")] 29 29 [PluginFile("HeuristicLab.Problems.DataAnalysis.Views-3.4.dll", PluginFileType.Assembly)] 30 30 [PluginDependency("HeuristicLab.ALGLIB", "3.7.0")] 31 [PluginDependency("HeuristicLab.Algorithms.DataAnalysis", "3.4")] 31 32 [PluginDependency("HeuristicLab.Analysis", "3.3")] 32 33 [PluginDependency("HeuristicLab.Collections", "3.3")] … … 44 45 [PluginDependency("HeuristicLab.Persistence", "3.3")] 45 46 [PluginDependency("HeuristicLab.Problems.DataAnalysis", "3.4")] 47 [PluginDependency("HeuristicLab.Problems.DataAnalysis.Symbolic.Regression", "3.4")] 46 48 [PluginDependency("HeuristicLab.Visualization.ChartControlsExtensions", "3.3")] 47 49 public class HeuristicLabProblemsDataAnalysisViewsPlugin : PluginBase { -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/ProblemDataView.Designer.cs
r10553 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 46 46 private void InitializeComponent() { 47 47 this.FeatureCorrelationButton = new System.Windows.Forms.Button(); 48 this.DataPreprocessingButton = new System.Windows.Forms.Button(); 48 49 ((System.ComponentModel.ISupportInitialize)(this.errorProvider)).BeginInit(); 49 50 this.SuspendLayout(); … … 71 72 this.FeatureCorrelationButton.Click += new System.EventHandler(this.FeatureCorrelationButton_Click); 72 73 // 74 // DataPreprocessingButton 75 // 76 this.DataPreprocessingButton.Location = new System.Drawing.Point(311, 45); 77 this.DataPreprocessingButton.Name = "DataPreprocessingButton"; 78 this.DataPreprocessingButton.Size = new System.Drawing.Size(121, 24); 79 this.DataPreprocessingButton.TabIndex = 5; 80 this.DataPreprocessingButton.Text = "Data Preprocessing"; 81 this.DataPreprocessingButton.UseVisualStyleBackColor = true; 82 this.DataPreprocessingButton.Click += new System.EventHandler(this.DataPreprocessingButton_Click); 83 // 73 84 // ProblemDataView 74 85 // 75 86 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 76 87 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 88 this.Controls.Add(this.DataPreprocessingButton); 77 89 this.Controls.Add(this.FeatureCorrelationButton); 78 90 this.Name = "ProblemDataView"; … … 82 94 this.Controls.SetChildIndex(this.nameLabel, 0); 83 95 this.Controls.SetChildIndex(this.FeatureCorrelationButton, 0); 96 this.Controls.SetChildIndex(this.DataPreprocessingButton, 0); 84 97 ((System.ComponentModel.ISupportInitialize)(this.errorProvider)).EndInit(); 85 98 this.ResumeLayout(false); … … 91 104 92 105 protected System.Windows.Forms.Button FeatureCorrelationButton; 106 protected System.Windows.Forms.Button DataPreprocessingButton; 93 107 94 108 } -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/ProblemDataView.cs
r10553 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 29 29 using HeuristicLab.MainForm; 30 30 using HeuristicLab.MainForm.WindowsForms; 31 using HeuristicLab.PluginInfrastructure; 31 32 32 33 namespace HeuristicLab.Problems.DataAnalysis.Views { … … 100 101 e.Effect = e.AllowedEffect; 101 102 } 103 104 private void DataPreprocessingButton_Click(object sender, EventArgs e) { 105 var preprocessingStarters = ApplicationManager.Manager.GetInstances<IDataPreprocessorStarter>(); 106 var starter = preprocessingStarters.FirstOrDefault(); 107 // TODO: handle possible multiple starters 108 if (starter != null) { 109 starter.Start(Content, this); 110 } 111 } 102 112 } 103 113 } -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Properties/AssemblyInfo.cs.frame
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 31 31 [assembly: AssemblyCompany("")] 32 32 [assembly: AssemblyProduct("HeuristicLab")] 33 [assembly: AssemblyCopyright("(c) 2002-201 3HEAL")]33 [assembly: AssemblyCopyright("(c) 2002-2015 HEAL")] 34 34 [assembly: AssemblyTrademark("")] 35 35 [assembly: AssemblyCulture("")] … … 53 53 // by using the '*' as shown below: 54 54 [assembly: AssemblyVersion("3.4.0.0")] 55 [assembly: AssemblyFileVersion("3.4. 5.$WCREV$")]55 [assembly: AssemblyFileVersion("3.4.8.$WCREV$")] -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionEnsembleSolutionModelView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionEnsembleSolutionModelView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionFeatureCorrelationView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionFeatureCorrelationView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionErrorCharacteristicsCurveView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 51 51 this.label1 = new System.Windows.Forms.Label(); 52 52 this.cmbSamples = new System.Windows.Forms.ComboBox(); 53 this.residualComboBox = new System.Windows.Forms.ComboBox(); 53 54 ((System.ComponentModel.ISupportInitialize)(this.chart)).BeginInit(); 54 55 this.SuspendLayout(); … … 56 57 // chart 57 58 // 58 this.chart.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 59 | System.Windows.Forms.AnchorStyles.Left) 60 | System.Windows.Forms.AnchorStyles.Right))); 59 this.chart.AllowDrop = true; 60 this.chart.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 61 | System.Windows.Forms.AnchorStyles.Left) 62 | System.Windows.Forms.AnchorStyles.Right))); 61 63 chartArea1.Name = "ChartArea1"; 62 64 this.chart.ChartAreas.Add(chartArea1); … … 70 72 this.chart.TabIndex = 0; 71 73 this.chart.Text = "chart"; 74 this.chart.DragDrop += new System.Windows.Forms.DragEventHandler(this.chart_DragDrop); 75 this.chart.DragEnter += new System.Windows.Forms.DragEventHandler(this.chart_DragEnter); 72 76 this.chart.MouseDoubleClick += new System.Windows.Forms.MouseEventHandler(this.Chart_MouseDoubleClick); 73 77 this.chart.MouseMove += new System.Windows.Forms.MouseEventHandler(this.chart_MouseMove); … … 92 96 this.cmbSamples.SelectedIndexChanged += new System.EventHandler(this.cmbSamples_SelectedIndexChanged); 93 97 // 98 // residualComboBox 99 // 100 this.residualComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 101 this.residualComboBox.FormattingEnabled = true; 102 this.residualComboBox.Items.AddRange(new object[] { 103 "Absolute error", 104 "Squared error", 105 "Relative error"}); 106 this.residualComboBox.Location = new System.Drawing.Point(183, 3); 107 this.residualComboBox.Name = "residualComboBox"; 108 this.residualComboBox.Size = new System.Drawing.Size(121, 21); 109 this.residualComboBox.TabIndex = 5; 110 this.residualComboBox.SelectedIndexChanged += new System.EventHandler(this.residualComboBox_SelectedIndexChanged); 111 // 94 112 // RegressionSolutionErrorCharacteristicsCurveView 95 113 // 96 114 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Inherit; 115 this.Controls.Add(this.residualComboBox); 97 116 this.Controls.Add(this.label1); 98 117 this.Controls.Add(this.cmbSamples); … … 111 130 protected System.Windows.Forms.Label label1; 112 131 protected System.Windows.Forms.ComboBox cmbSamples; 132 protected System.Windows.Forms.ComboBox residualComboBox; 113 133 } 114 134 } -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionErrorCharacteristicsCurveView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 25 25 using System.Windows.Forms; 26 26 using System.Windows.Forms.DataVisualization.Charting; 27 using HeuristicLab.Algorithms.DataAnalysis; 28 using HeuristicLab.Common; 27 29 using HeuristicLab.MainForm; 30 using HeuristicLab.Optimization; 28 31 29 32 namespace HeuristicLab.Problems.DataAnalysis.Views { … … 45 48 cmbSamples.SelectedIndex = 0; 46 49 50 residualComboBox.SelectedIndex = 0; 51 47 52 chart.CustomizeAllChartAreas(); 48 chart.ChartAreas[0].AxisX.Title = "Absolute Error";53 chart.ChartAreas[0].AxisX.Title = residualComboBox.SelectedItem.ToString(); 49 54 chart.ChartAreas[0].AxisX.Minimum = 0.0; 50 chart.ChartAreas[0].AxisX.Maximum = 1.0;55 chart.ChartAreas[0].AxisX.Maximum = 0.0; 51 56 chart.ChartAreas[0].AxisX.IntervalAutoMode = IntervalAutoMode.VariableCount; 52 57 chart.ChartAreas[0].CursorX.Interval = 0.01; … … 59 64 } 60 65 66 // the view holds one regression solution as content but also contains several other regression solutions for comparison 67 // the following invariants must hold 68 // (Solutions.IsEmpty && Content == null) || 69 // (Solutions[0] == Content && Solutions.All(s => s.ProblemData.TargetVariable == Content.TargetVariable)) 70 61 71 public new IRegressionSolution Content { 62 72 get { return (IRegressionSolution)base.Content; } 63 73 set { base.Content = value; } 64 74 } 75 76 private readonly IList<IRegressionSolution> solutions = new List<IRegressionSolution>(); 77 public IEnumerable<IRegressionSolution> Solutions { 78 get { return solutions.AsEnumerable(); } 79 } 80 65 81 public IRegressionProblemData ProblemData { 66 82 get { … … 83 99 protected virtual void Content_ModelChanged(object sender, EventArgs e) { 84 100 if (InvokeRequired) Invoke((Action<object, EventArgs>)Content_ModelChanged, sender, e); 85 else UpdateChart(); 101 else { 102 // recalculate baseline solutions (for symbolic regression models the features used in the model might have changed) 103 solutions.Clear(); // remove all 104 solutions.Add(Content); // re-add the first solution 105 // and recalculate all other solutions 106 foreach (var sol in CreateBaselineSolutions()) { 107 solutions.Add(sol); 108 } 109 UpdateChart(); 110 } 86 111 } 87 112 protected virtual void Content_ProblemDataChanged(object sender, EventArgs e) { 88 113 if (InvokeRequired) Invoke((Action<object, EventArgs>)Content_ProblemDataChanged, sender, e); 89 114 else { 115 // recalculate baseline solutions 116 solutions.Clear(); // remove all 117 solutions.Add(Content); // re-add the first solution 118 // and recalculate all other solutions 119 foreach (var sol in CreateBaselineSolutions()) { 120 solutions.Add(sol); 121 } 90 122 UpdateChart(); 91 123 } … … 93 125 protected override void OnContentChanged() { 94 126 base.OnContentChanged(); 127 // the content object is always stored as the first element in solutions 128 solutions.Clear(); 129 ReadOnly = Content == null; 130 if (Content != null) { 131 // recalculate all solutions 132 solutions.Add(Content); 133 if (ProblemData.TrainingIndices.Any()) { 134 foreach (var sol in CreateBaselineSolutions()) 135 solutions.Add(sol); 136 // more solutions can be added by drag&drop 137 } 138 } 95 139 UpdateChart(); 96 140 } … … 99 143 chart.Series.Clear(); 100 144 chart.Annotations.Clear(); 145 chart.ChartAreas[0].AxisX.Maximum = 0.0; 146 chart.ChartAreas[0].CursorX.Interval = 0.01; 147 101 148 if (Content == null) return; 102 103 var constantModel = CreateConstantModel(); 104 var originalValues = GetOriginalValues().ToList(); 105 var baselineEstimatedValues = GetEstimatedValues(constantModel); 106 var baselineResiduals = GetResiduals(originalValues, baselineEstimatedValues); 107 108 baselineResiduals.Sort(); 109 chart.ChartAreas[0].AxisX.Maximum = Math.Ceiling(baselineResiduals.Last()); 110 chart.ChartAreas[0].CursorX.Interval = baselineResiduals.First() / 100; 111 112 Series baselineSeries = new Series("Baseline"); 113 baselineSeries.ChartType = SeriesChartType.FastLine; 114 UpdateSeries(baselineResiduals, baselineSeries); 115 baselineSeries.ToolTip = "Area over Curve: " + CalculateAreaOverCurve(baselineSeries); 116 baselineSeries.Tag = constantModel; 117 baselineSeries.LegendToolTip = "Double-click to open model"; 118 chart.Series.Add(baselineSeries); 119 120 AddRegressionSolution(Content); 121 } 122 123 protected void AddRegressionSolution(IRegressionSolution solution) { 149 if (cmbSamples.SelectedItem.ToString() == TrainingSamples && !ProblemData.TrainingIndices.Any()) return; 150 if (cmbSamples.SelectedItem.ToString() == TestSamples && !ProblemData.TestIndices.Any()) return; 151 152 foreach (var sol in Solutions) { 153 AddSeries(sol); 154 } 155 156 chart.ChartAreas[0].AxisX.Title = residualComboBox.SelectedItem.ToString(); 157 } 158 159 protected void AddSeries(IRegressionSolution solution) { 124 160 if (chart.Series.Any(s => s.Name == solution.Name)) return; 125 161 … … 127 163 solutionSeries.Tag = solution; 128 164 solutionSeries.ChartType = SeriesChartType.FastLine; 129 var estimatedValues = GetResiduals(GetOriginalValues(), GetEstimatedValues(solution)); 130 UpdateSeries(estimatedValues, solutionSeries); 165 var residuals = GetResiduals(GetOriginalValues(), GetEstimatedValues(solution)); 166 167 var maxValue = residuals.Max(); 168 if (maxValue >= chart.ChartAreas[0].AxisX.Maximum) { 169 double scale = Math.Pow(10, Math.Floor(Math.Log10(maxValue))); 170 var maximum = scale * (1 + (int)(maxValue / scale)); 171 chart.ChartAreas[0].AxisX.Maximum = maximum; 172 chart.ChartAreas[0].CursorX.Interval = residuals.Min() / 100; 173 } 174 175 UpdateSeries(residuals, solutionSeries); 176 131 177 solutionSeries.ToolTip = "Area over Curve: " + CalculateAreaOverCurve(solutionSeries); 132 178 solutionSeries.LegendToolTip = "Double-click to open model"; … … 202 248 203 249 protected virtual List<double> GetResiduals(IEnumerable<double> originalValues, IEnumerable<double> estimatedValues) { 204 return originalValues.Zip(estimatedValues, (x, y) => Math.Abs(x - y)).ToList(); 250 switch (residualComboBox.SelectedItem.ToString()) { 251 case "Absolute error": return originalValues.Zip(estimatedValues, (x, y) => Math.Abs(x - y)).ToList(); 252 case "Squared error": return originalValues.Zip(estimatedValues, (x, y) => (x - y) * (x - y)).ToList(); 253 case "Relative error": return originalValues.Zip(estimatedValues, (x, y) => x.IsAlmost(0.0) ? -1 : Math.Abs((x - y) / x)) 254 .Where(x => x > 0) // remove entries where the original value is 0 255 .ToList(); 256 default: throw new NotSupportedException(); 257 } 205 258 } 206 259 … … 225 278 } 226 279 227 #region Baseline228 280 private void Chart_MouseDoubleClick(object sender, MouseEventArgs e) { 229 281 HitTestResult result = chart.HitTest(e.X, e.Y); … … 233 285 } 234 286 235 private IRegressionSolution CreateConstantModel() { 287 protected virtual IEnumerable<IRegressionSolution> CreateBaselineSolutions() { 288 yield return CreateConstantSolution(); 289 yield return CreateLinearSolution(); 290 } 291 292 private IRegressionSolution CreateConstantSolution() { 236 293 double averageTrainingTarget = ProblemData.Dataset.GetDoubleValues(ProblemData.TargetVariable, ProblemData.TrainingIndices).Average(); 237 294 var model = new ConstantRegressionModel(averageTrainingTarget); 238 var solution = new ConstantRegressionSolution(model, (IRegressionProblemData)ProblemData.Clone());239 solution.Name = "Baseline ";295 var solution = new ConstantRegressionSolution(model, (IRegressionProblemData)ProblemData.Clone()); 296 solution.Name = "Baseline (constant)"; 240 297 return solution; 241 298 } 242 #endregion 299 private IRegressionSolution CreateLinearSolution() { 300 double rmsError, cvRmsError; 301 var solution = LinearRegression.CreateLinearRegressionSolution((IRegressionProblemData)ProblemData.Clone(), out rmsError, out cvRmsError); 302 solution.Name = "Baseline (linear)"; 303 return solution; 304 } 243 305 244 306 private void chart_MouseMove(object sender, MouseEventArgs e) { … … 250 312 } 251 313 } 314 315 private void chart_DragDrop(object sender, DragEventArgs e) { 316 if (e.Data.GetDataPresent(HeuristicLab.Common.Constants.DragDropDataFormat)) { 317 318 var data = e.Data.GetData(HeuristicLab.Common.Constants.DragDropDataFormat); 319 var dataAsRegressionSolution = data as IRegressionSolution; 320 var dataAsResult = data as IResult; 321 322 if (dataAsRegressionSolution != null) { 323 solutions.Add((IRegressionSolution)dataAsRegressionSolution.Clone()); 324 } else if (dataAsResult != null && dataAsResult.Value is IRegressionSolution) { 325 solutions.Add((IRegressionSolution)dataAsResult.Value.Clone()); 326 } 327 328 UpdateChart(); 329 } 330 } 331 332 private void chart_DragEnter(object sender, DragEventArgs e) { 333 e.Effect = DragDropEffects.None; 334 if (!e.Data.GetDataPresent(HeuristicLab.Common.Constants.DragDropDataFormat)) return; 335 336 var data = e.Data.GetData(HeuristicLab.Common.Constants.DragDropDataFormat); 337 var dataAsRegressionSolution = data as IRegressionSolution; 338 var dataAsResult = data as IResult; 339 340 if (!ReadOnly && 341 (dataAsRegressionSolution != null || (dataAsResult != null && dataAsResult.Value is IRegressionSolution))) { 342 e.Effect = DragDropEffects.Copy; 343 } 344 } 345 346 private void residualComboBox_SelectedIndexChanged(object sender, EventArgs e) { 347 UpdateChart(); 348 } 252 349 } 253 350 } -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionEstimatedValuesView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionEstimatedValuesView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionLineChartView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionLineChartView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionResidualHistogram.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionResidualHistogram.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionScatterPlotView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionScatterPlotView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 142 142 else { 143 143 string targetVariableName = Content.ProblemData.TargetVariable; 144 Datasetdataset = Content.ProblemData.Dataset;144 var dataset = Content.ProblemData.Dataset; 145 145 if (this.chart.Series[ALL_SERIES].Points.Count > 0) 146 146 this.chart.Series[ALL_SERIES].Points.DataBindXY(Content.EstimatedValues.ToArray(), "", -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionTimeframeFeatureCorrelationView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionTimeframeFeatureCorrelationView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/ClassificationEnsembleSolutionView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/ClassificationEnsembleSolutionView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/ClassificationSolutionView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/ClassificationSolutionView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/ClusteringSolutionView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/ClusteringSolutionView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/DataAnalysisSolutionView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/DataAnalysisSolutionView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/DiscriminantFunctionClassificationSolutionView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/DiscriminantFunctionClassificationSolutionView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/NamedDataAnalysisSolutionView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/NamedDataAnalysisSolutionView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/RegressionEnsembleSolutionView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/RegressionEnsembleSolutionView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/RegressionSolutionView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/RegressionSolutionView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/TimeSeriesPrognosisSolutionView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/Solution Views/TimeSeriesPrognosisSolutionView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/TimeSeriesPrognosis/TimeSeriesPrognosisResultsView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/TimeSeriesPrognosis/TimeSeriesPrognosisResultsView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/TimeSeriesPrognosis/TimeSeriesPrognosisSolutionErrorCharacteristicsCurveView.Designer.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/ClassificationModelComparison/HeuristicLab.Problems.DataAnalysis.Views/3.4/TimeSeriesPrognosis/TimeSeriesPrognosisSolutionErrorCharacteristicsCurveView.cs
r10556 r13082 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 22 22 using System.Collections.Generic; 23 23 using System.Linq; 24 using System.Windows.Forms;25 24 using HeuristicLab.MainForm; 26 using HeuristicLab.MainForm.WindowsForms; 25 27 26 namespace HeuristicLab.Problems.DataAnalysis.Views { 28 27 [View("Error Characteristics Curve")] 29 28 [Content(typeof(ITimeSeriesPrognosisSolution))] 30 29 public partial class TimeSeriesPrognosisSolutionErrorCharacteristicsCurveView : RegressionSolutionErrorCharacteristicsCurveView { 31 32 33 30 public TimeSeriesPrognosisSolutionErrorCharacteristicsCurveView() 34 31 : base() { … … 47 44 } 48 45 49 protected override void UpdateChart() {50 base.UpdateChart();51 if (Content == null) return;46 protected override IEnumerable<IRegressionSolution> CreateBaselineSolutions() { 47 foreach (var sol in base.CreateBaselineSolutions()) 48 yield return sol; 52 49 50 IEnumerable<double> trainingStartValues = ProblemData.Dataset.GetDoubleValues(ProblemData.TargetVariable, ProblemData.TrainingIndices.Select(r => r - 1).Where(r => r > 0)).ToList(); 53 51 //AR1 model 54 52 double alpha, beta; 55 53 OnlineCalculatorError errorState; 56 IEnumerable<double> trainingStartValues = ProblemData.Dataset.GetDoubleValues(ProblemData.TargetVariable, ProblemData.TrainingIndices.Select(r => r - 1).Where(r => r > 0)).ToList();57 54 OnlineLinearScalingParameterCalculator.Calculate(ProblemData.Dataset.GetDoubleValues(ProblemData.TargetVariable, ProblemData.TrainingIndices.Where(x => x > 0)), trainingStartValues, out alpha, out beta, out errorState); 58 var AR1model= new TimeSeriesPrognosisAutoRegressiveModel(ProblemData.TargetVariable, new double[] { beta }, alpha).CreateTimeSeriesPrognosisSolution(ProblemData);59 AR1model.Name = "AR(1) Model";60 AddRegressionSolution(AR1model);55 var ar1Solution = new TimeSeriesPrognosisAutoRegressiveModel(ProblemData.TargetVariable, new double[] { beta }, alpha).CreateTimeSeriesPrognosisSolution(ProblemData); 56 ar1Solution.Name = "AR(1)"; 57 yield return ar1Solution; 61 58 } 62 59 }
Note: See TracChangeset
for help on using the changeset viewer.