Changeset 14309
- Timestamp:
- 09/26/16 18:26:45 (8 years ago)
- Location:
- stable
- Files:
-
- 2 deleted
- 17 edited
- 6 copied
Legend:
- Unmodified
- Added
- Removed
-
stable
- Property svn:mergeinfo changed
/trunk/sources merged: 14255
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Problems.DataAnalysis.Symbolic
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic merged: 14255
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification.Views
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification.Views merged: 14255
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification.Views/3.4/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification.Views-3.4.csproj
r12707 r14309 144 144 <Compile Include="SymbolicDiscriminantFunctionClassificationSolutionView.Designer.cs"> 145 145 <DependentUpon>SymbolicDiscriminantFunctionClassificationSolutionView.cs</DependentUpon> 146 </Compile> 147 <Compile Include="SymbolicClassificationModelMathView.cs"> 148 <SubType>UserControl</SubType> 149 </Compile> 150 <Compile Include="SymbolicClassificationModelMathView.designer.cs"> 151 <DependentUpon>SymbolicClassificationModelMathView.cs</DependentUpon> 146 152 </Compile> 147 153 <None Include="HeuristicLab.snk" /> -
stable/HeuristicLab.Problems.DataAnalysis.Symbolic.Regression.Views
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic.Regression.Views merged: 14255
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Problems.DataAnalysis.Symbolic.Regression.Views/3.4/HeuristicLab.Problems.DataAnalysis.Symbolic.Regression.Views-3.4.csproj
r11920 r14309 121 121 <Compile Include="InteractiveSymbolicRegressionSolutionSimplifierView.Designer.cs"> 122 122 <DependentUpon>InteractiveSymbolicRegressionSolutionSimplifierView.cs</DependentUpon> 123 </Compile> 124 <Compile Include="SymbolicRegressionModelMathView.cs"> 125 <SubType>UserControl</SubType> 126 </Compile> 127 <Compile Include="SymbolicRegressionModelMathView.designer.cs"> 128 <DependentUpon>SymbolicRegressionModelMathView.cs</DependentUpon> 123 129 </Compile> 124 130 <Compile Include="Plugin.cs" /> -
stable/HeuristicLab.Problems.DataAnalysis.Symbolic.Views
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic.Views merged: 14255
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Problems.DataAnalysis.Symbolic.Views/3.4/HeuristicLab.Problems.DataAnalysis.Symbolic.Views-3.4.csproj
r12707 r14309 121 121 <DependentUpon>InteractiveSymbolicExpressionTreeChart.cs</DependentUpon> 122 122 </Compile> 123 <Compile Include=" MathSymbolicDataAnalysisModelView.cs">124 <SubType>UserControl</SubType> 125 </Compile> 126 <Compile Include=" MathSymbolicDataAnalysisModelView.designer.cs">127 <DependentUpon> MathSymbolicDataAnalysisModelView.cs</DependentUpon>123 <Compile Include="SymbolicDataAnalysisModelMathView.cs"> 124 <SubType>UserControl</SubType> 125 </Compile> 126 <Compile Include="SymbolicDataAnalysisModelMathView.designer.cs"> 127 <DependentUpon>SymbolicDataAnalysisModelMathView.cs</DependentUpon> 128 128 </Compile> 129 129 <Compile Include="Plugin.cs" /> -
stable/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Formatters/SymbolicDataAnalysisExpressionLatexFormatter.cs
r14186 r14309 36 36 private int targetCount; 37 37 private int currentLag; 38 private string targetVariable; 39 private bool containsTimeSeriesSymbol; 38 40 39 41 [StorableConstructor] … … 55 57 56 58 public string Format(ISymbolicExpressionTree symbolicExpressionTree) { 59 return Format(symbolicExpressionTree, null); 60 } 61 public string Format(ISymbolicExpressionTree symbolicExpressionTree, string targetVariable) { 57 62 try { 58 63 StringBuilder strBuilder = new StringBuilder(); 59 64 constants.Clear(); 65 this.targetVariable = targetVariable; 66 containsTimeSeriesSymbol = symbolicExpressionTree.IterateNodesBreadth().Any(n => IsTimeSeriesSymbol(n.Symbol)); 60 67 strBuilder.AppendLine(FormatRecursively(symbolicExpressionTree.Root)); 61 68 return strBuilder.ToString(); … … 64 71 return ex.Message + Environment.NewLine + ex.StackTrace; 65 72 } 73 } 74 static bool IsTimeSeriesSymbol(ISymbol s) { 75 return s is TimeLag || s is Integral || s is Derivative || s is LaggedVariable; 66 76 } 67 77 … … 197 207 strBuilder.Append(invokeNode.Symbol.FunctionName + @" \left( "); 198 208 } else if (node.Symbol is StartSymbol) { 199 strBuilder.Append("target_" + (targetCount++) + "(t) & = ");209 FormatStartSymbol(strBuilder); 200 210 } else if (node.Symbol is Argument) { 201 211 var argSym = node.Symbol as Argument; … … 303 313 } else if (node.Symbol is StartSymbol) { 304 314 strBuilder.Append(@"\\" + Environment.NewLine); 305 strBuilder.Append("target_" + (targetCount++) + "(t) & = ");315 FormatStartSymbol(strBuilder); 306 316 } else if (node.Symbol is Power) { 307 317 strBuilder.Append(@"\right) ^ { \operatorname{round} \left("); … … 433 443 } 434 444 445 private void FormatStartSymbol(StringBuilder strBuilder) { 446 strBuilder.Append(targetVariable ?? "target_" + (targetCount++)); 447 if (containsTimeSeriesSymbol) 448 strBuilder.Append("(t)"); 449 strBuilder.Append(" & = "); 450 } 451 435 452 private string LagToString(int lag) { 436 453 if (lag < 0) { -
stable/HeuristicLab.Problems.DataAnalysis.Views
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Problems.DataAnalysis.Views merged: 14255
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationSolutionConfusionMatrixView.cs
r14186 r14309 76 76 dataGridView.RowCount = 1; 77 77 dataGridView.ColumnCount = 1; 78 dataGridView.TopLeftHeaderCell.Value = string.Empty; 78 79 } else { 79 80 dataGridView.ColumnCount = Content.ProblemData.Classes + 1; … … 91 92 dataGridView.AutoResizeColumns(DataGridViewAutoSizeColumnsMode.ColumnHeader); 92 93 dataGridView.AutoResizeRowHeadersWidth(DataGridViewRowHeadersWidthSizeMode.AutoSizeToAllHeaders); 94 95 dataGridView.TopLeftHeaderCell.Style.Alignment = DataGridViewContentAlignment.MiddleCenter; 96 dataGridView.TopLeftHeaderCell.Value = Content.Model.TargetVariable; 93 97 94 98 FillDataGridView(); -
stable/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/DiscriminantFunctionClassificationSolutionThresholdView.cs
r14186 r14309 120 120 IEnumerator<double> classValueEnumerator = Content.ProblemData.ClassValues.OrderBy(x => x).GetEnumerator(); 121 121 while (classNameEnumerator.MoveNext() && classValueEnumerator.MoveNext()) { 122 Series series = new Series( classNameEnumerator.Current);122 Series series = new Series(Content.Model.TargetVariable + ": " + classNameEnumerator.Current); 123 123 series.ChartType = SeriesChartType.FastPoint; 124 124 series.Tag = classValueEnumerator.Current; -
stable/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/ConfidenceRegressionSolutionLineChartView.cs
r14186 r14309 28 28 using HeuristicLab.Problems.DataAnalysis; 29 29 using HeuristicLab.Problems.DataAnalysis.Views; 30 using HeuristicLab.Visualization.ChartControlsExtensions; 30 31 31 32 namespace HeuristicLab.Algorithms.DataAnalysis.Views { … … 109 110 // target 110 111 this.chart.Series.Add(TARGETVARIABLE_SERIES_NAME); 111 this.chart.Series[TARGETVARIABLE_SERIES_NAME].LegendText = Content.ProblemData.TargetVariable;112 this.chart.Series[TARGETVARIABLE_SERIES_NAME].LegendText = TARGETVARIABLE_SERIES_NAME; 112 113 this.chart.Series[TARGETVARIABLE_SERIES_NAME].ChartType = SeriesChartType.FastLine; 113 114 this.chart.Series[TARGETVARIABLE_SERIES_NAME].Points.DataBindXY(Enumerable.Range(0, Content.ProblemData.Dataset.Rows).ToArray(), … … 126 127 var s3Color = chart.Series[3].Color; 127 128 this.chart.PaletteCustomColors = new Color[] { s1Color, s2Color, s3Color, s0Color }; 129 130 // set the y-axis 131 var axisY = this.chart.ChartAreas[0].AxisY; 132 axisY.Title = Content.ProblemData.TargetVariable; 133 double min = double.MaxValue, max = double.MinValue; 134 foreach (var point in chart.Series.SelectMany(x => x.Points)) { 135 if (!point.YValues.Any() || double.IsInfinity(point.YValues[0]) || double.IsNaN(point.YValues[0])) 136 continue; 137 var y = point.YValues[0]; 138 if (y < min) 139 min = y; 140 if (y > max) 141 max = y; 142 } 143 144 double axisMin, axisMax, axisInterval; 145 ChartUtil.CalculateOptimalAxisInterval(min, max, out axisMin, out axisMax, out axisInterval); 146 axisY.Minimum = axisMin; 147 axisY.Maximum = axisMax; 148 axisY.Interval = axisInterval; 128 149 129 150 UpdateCursorInterval(); -
stable/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionErrorCharacteristicsCurveView.cs
r14186 r14309 154 154 } 155 155 156 chart.ChartAreas[0].AxisX.Title = residualComboBox.SelectedItem.ToString();156 chart.ChartAreas[0].AxisX.Title = string.Format("{0} ({1})", residualComboBox.SelectedItem, Content.ProblemData.TargetVariable); 157 157 } 158 158 -
stable/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionLineChartView.cs
r14186 r14309 64 64 65 65 this.chart.Series.Add(TARGETVARIABLE_SERIES_NAME); 66 this.chart.Series[TARGETVARIABLE_SERIES_NAME].LegendText = Content.ProblemData.TargetVariable;66 this.chart.Series[TARGETVARIABLE_SERIES_NAME].LegendText = TARGETVARIABLE_SERIES_NAME; 67 67 this.chart.Series[TARGETVARIABLE_SERIES_NAME].ChartType = SeriesChartType.FastLine; 68 68 this.chart.Series[TARGETVARIABLE_SERIES_NAME].Points.DataBindXY(Enumerable.Range(0, Content.ProblemData.Dataset.Rows).ToArray(), … … 97 97 this.ToggleSeriesData(this.chart.Series[ESTIMATEDVALUES_ALL_SERIES_NAME]); 98 98 99 // set the y-axis bounds99 // set the y-axis 100 100 var axisY = this.chart.ChartAreas[0].AxisY; 101 axisY.Title = Content.ProblemData.TargetVariable; 101 102 double min = double.MaxValue, max = double.MinValue; 102 103 foreach (var point in chart.Series.SelectMany(x => x.Points)) { -
stable/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionResidualHistogram.cs
r14186 r14309 96 96 97 97 ChartArea chartArea = chart.ChartAreas[0]; 98 chartArea.AxisX.Title = string.Format("Residuals ({0})", Content.ProblemData.TargetVariable); 98 99 chartArea.AxisX.Minimum = -roundedMax - intervalWidth; 99 100 chartArea.AxisX.Maximum = roundedMax + intervalWidth; -
stable/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionScatterPlotView.cs
r14186 r14309 172 172 double axisMin, axisMax, axisInterval; 173 173 ChartUtil.CalculateOptimalAxisInterval(min, max, out axisMin, out axisMax, out axisInterval); 174 this.chart.ChartAreas[0].AxisX.Title = "Estimated " + targetVariableName; 174 175 this.chart.ChartAreas[0].AxisX.Maximum = axisMax; 175 176 this.chart.ChartAreas[0].AxisX.Minimum = axisMin; 176 177 this.chart.ChartAreas[0].AxisX.Interval = axisInterval; 178 this.chart.ChartAreas[0].AxisY.Title = targetVariableName; 177 179 this.chart.ChartAreas[0].AxisY.Maximum = axisMax; 178 180 this.chart.ChartAreas[0].AxisY.Minimum = axisMin;
Note: See TracChangeset
for help on using the changeset viewer.