Changeset 12135
 Timestamp:
 03/05/15 10:38:34 (8 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

trunk/sources/HeuristicLab.Analysis/3.3/Statistics/NormalDistribution.cs
r12134 r12135 37 37 } 38 38 39 // based on the idea from http://www.statmethods.net/graphs/density.html 40 public static List<Tuple<double, double>> Density(double[] x, int nrOfPoints, double stepWidth) { 39 40 // the scale (sigma) of the kernel is a parameter 41 public static List<Tuple<double, double>> Density(double[] x, int nrOfPoints, double stepWidth, double sigma = 1.0) { 41 42 // calculate grid for which to estimate the density 42 43 double[] newX = new double[nrOfPoints]; … … 53 54 } 54 55 55 // the scale (std.dev. of the kernel is a parameter)56 var sigma = 1.0; // TODO allow configuration in the view57 56 // for each of the points for which we want to calculate the density 58 57 // we sum up all the densities of the observed points assuming they are at the center of a normal distribution
Note: See TracChangeset
for help on using the changeset viewer.