|
|
|||||||||||||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||||||||||||
java.lang.Objectde.lmu.ifi.dbs.elki.data.synthetic.bymodel.distribution.NormalDistribution
public final class NormalDistribution
Simple generator for a Gaussian = Normal Distribution
| Field Summary | |
|---|---|
private double |
mean
Mean value for the generator |
private Random |
random
The random generator. |
private double |
stddev
Standard deviation |
| Constructor Summary | |
|---|---|
NormalDistribution(double mean,
double stddev,
Random random)
Constructor for Gaussian generator |
|
| Method Summary | |
|---|---|
double |
explain(double val)
Return the PDF of the generators distribution |
double |
generate()
Generate a random value with the generators parameters |
double |
getMean()
|
double |
getStddev()
|
private static double |
phi(double x)
Standardized Gaussian PDF |
static double |
phi(double x,
double mu,
double sigma)
Gaussian distribution PDF |
String |
toString()
Simple toString explaining the distribution parameters. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private double mean
private double stddev
private Random random
| Constructor Detail |
|---|
public NormalDistribution(double mean,
double stddev,
Random random)
mean - Meanstddev - Standard Deviationrandom - Random generator| Method Detail |
|---|
private static double phi(double x)
x - query value
public static double phi(double x,
double mu,
double sigma)
x - query valuemu - meansigma - standard distribution
public double explain(double val)
explain in interface Distributionval - existing value
public double generate()
generate in interface Distributionpublic String toString()
toString in interface DistributiontoString in class Objectpublic double getMean()
public double getStddev()
|
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||