Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
05/04/21 14:29:30 (3 years ago)
Author:
chaider
Message:

#3075

  • Added target without noise to noisy instances
  • Moved noise calculation to descriptor
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Feynman/FeynmanBonus6.cs

    r17966 r17973  
    3737
    3838    protected override string[] VariableNames {
    39       get { return new[] {"I_0", "alpha", "delta", "n", noiseRatio == null ? "I" : "I_noise"}; }
     39      get { return noiseRatio == null ? new[] { "I_0", "alpha", "delta", "n", "I" } : new[] { "I_0", "alpha", "delta", "n", "I", "I_noise" }; }
    4040    }
    4141
     
    7373      }
    7474
    75       if (noiseRatio != null) {
    76         var I_noise     = new List<double>();
    77         var sigma_noise = (double) Math.Sqrt(noiseRatio.Value) * I.StandardDeviationPop();
    78         I_noise.AddRange(I.Select(md => md + NormalDistributedRandomPolar.NextDouble(rand, 0, sigma_noise)));
    79         data.Remove(I);
    80         data.Add(I_noise);
    81       }
     75      var targetNoise = GetNoisyTarget(I, rand);
     76      if (targetNoise != null) data.Add(targetNoise);
    8277
    8378      return data;
Note: See TracChangeset for help on using the changeset viewer.