Free cookie consent management tool by TermsFeed Policy Generator

Changeset 8521


Ignore:
Timestamp:
08/23/12 11:21:29 (12 years ago)
Author:
ascheibe
Message:

#1886 added gradient to statistical tabular view

Location:
branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.AlgorithmBehavior.Analyzers/3.3
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.AlgorithmBehavior.Analyzers/3.3/HeuristicLab.Analysis.AlgorithmBehavior.Analyzers-3.3.csproj

    r8502 r8521  
    3838  </PropertyGroup>
    3939  <ItemGroup>
     40    <Reference Include="ALGLIB-3.6.0, Version=3.6.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
     41      <Private>False</Private>
     42    </Reference>
    4043    <Reference Include="HeuristicLab.Analysis-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
    4144      <Private>False</Private>
     
    114117  <ItemGroup>
    115118    <Compile Include="AlgorithmBehaviorHelpers.cs" />
     119    <Compile Include="LinearLeastSquaresFitting.cs" />
    116120    <Compile Include="RunCollectionStatisticalTabularView.cs">
    117121      <SubType>UserControl</SubType>
  • branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.AlgorithmBehavior.Analyzers/3.3/RunCollectionStatisticalTabularView.cs

    r8503 r8521  
    2424using System.Linq;
    2525using System.Windows.Forms;
     26using HeuristicLab.Analysis.AlgorithmBehavior.Analyzers;
    2627using HeuristicLab.Common;
    2728using HeuristicLab.Core.Views;
     
    155156      string rowName = (string)dataRowComboBox.SelectedItem;
    156157
    157       string[] columnNames = new string[] { "Count", "Minimum", "Maximum", "Average", "Median", "Standard Deviation", "Variance", "25th Percentile", "75th Percentile" };
     158      string[] columnNames = new string[] { "Count", "Minimum", "Maximum", "Average", "Median", "Standard Deviation", "Variance", "25th Percentile", "75th Percentile", "Gradient", "Absolut Error" };
    158159
    159160      var runs = Content.Where(x => x.Results.ContainsKey(resultName));
     
    178179        double percentile25 = values.Percentile(0.25);
    179180        double percentile75 = values.Percentile(0.75);
    180 
    181         dt[i,0] = cnt.ToString();
    182         dt[i,1] = min.ToString();
    183         dt[i,2] = max.ToString();
    184         dt[i,3] = avg.ToString();
    185         dt[i,4] = median.ToString();
    186         dt[i,5] = stdDev.ToString();
    187         dt[i,6] = variance.ToString();
    188         dt[i,7] = percentile25.ToString();
    189         dt[i,8] = percentile75.ToString();
     181        double k, d, r;
     182        LinearLeastSquaresFitting.Calculate(values.ToArray(), out k, out d);
     183        r = LinearLeastSquaresFitting.CalculateError(values.ToArray(), k, d);
     184
     185        dt[i, 0] = cnt.ToString();
     186        dt[i, 1] = min.ToString();
     187        dt[i, 2] = max.ToString();
     188        dt[i, 3] = avg.ToString();
     189        dt[i, 4] = median.ToString();
     190        dt[i, 5] = stdDev.ToString();
     191        dt[i, 6] = variance.ToString();
     192        dt[i, 7] = percentile25.ToString();
     193        dt[i, 8] = percentile75.ToString();
     194        dt[i, 9] = k.ToString();
     195        dt[i, 10] = r.ToString();
    190196
    191197        i++;
Note: See TracChangeset for help on using the changeset viewer.