Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
11/07/17 19:49:23 (7 years ago)
Author:
gkronber
Message:

experimentation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/MathNetNumerics-Exploration-2789/Main/Program.cs

    r15450 r15459  
    1212  class Program {
    1313    static void Main(string[] args) {
    14       var provider = new HeuristicLab.Problems.Instances.DataAnalysis.VariousInstanceProvider();
    15       var problemData = provider.LoadData(provider.GetDataDescriptors().First(dd => dd.Name.Contains("Poly")));
    16       // var provider = new HeuristicLab.Problems.Instances.DataAnalysis.RegressionRealWorldInstanceProvider();
    17       // var problemData = provider.LoadData(provider.GetDataDescriptors().First(dd => dd.Name.Contains("Chem")));
     14
     15      var xs = HeuristicLab.Common.SequenceGenerator.GenerateSteps(-3.5, 3.5, 0.02, includeEnd: true).ToArray();
     16      var ys = xs.Select(xi => (1.0 / (Math.Sqrt(2 * Math.PI)) * Math.Exp(-0.5 * xi * xi))).ToArray();
     17
     18      alglib.hqrndstate state;
     19      alglib.hqrndseed(1234, 5678, out state);
     20      var ys_noise = ys.Select(yi => yi + alglib.hqrndnormal(state) * 0.01).ToArray();
     21
     22      SBART.SBART_Report rep;
     23      SBART.CalculateSBART(xs, ys_noise, "y", new string[] { "x" }, 1.0f, out rep);
     24
     25
     26      // var provider = new HeuristicLab.Problems.Instances.DataAnalysis.VariousInstanceProvider();
     27      // var problemData = provider.LoadData(provider.GetDataDescriptors().First(dd => dd.Name.Contains("Poly")));
     28      var provider = new HeuristicLab.Problems.Instances.DataAnalysis.RegressionRealWorldInstanceProvider();
     29      var problemData = provider.LoadData(provider.GetDataDescriptors().First(dd => dd.Name.Contains("Chem")));
    1830
    1931      var gam = new GAM();
    2032      gam.MaxIterations = 10;
    21       gam.MaxInteractions = 3;
     33      gam.MaxInteractions = 1;
    2234      gam.Problem.ProblemData = problemData;
    2335      gam.Start();
Note: See TracChangeset for help on using the changeset viewer.