|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdistribution.BasicMultivariateDistribution
distribution.MultivariateNormal
public class MultivariateNormal
Implements a multivariate normal distribution by extending
BasicMultivariateDistribution. Some methods are more streamlined by
exploiting the optimizations in the colt classes.
| Field Summary |
|---|
| Fields inherited from class distribution.BasicMultivariateDistribution |
|---|
randomEngine |
| Constructor Summary | |
|---|---|
MultivariateNormal()
|
|
| Method Summary | |
|---|---|
double |
densityAt(double[] x)
Computes the density at the given point. |
cern.colt.matrix.DoubleMatrix1D |
densityAt(cern.colt.matrix.DoubleMatrix2D x,
cern.colt.matrix.DoubleMatrix1D p)
Computes the density at the points comprising the rows of the input matrix, and places the result in the supplied vector. |
void |
nextSample(double[] arr)
Generates the next random sample of this distribution and places the result in the supplied array. |
cern.colt.matrix.DoubleMatrix2D |
nextSample(cern.colt.matrix.DoubleMatrix2D mat)
Generates the next m random samples of this distribution and places
the result in the supplied matrix. |
void |
setCovariance(cern.colt.matrix.DoubleMatrix2D covariance)
Sets the covariance of this distribution. |
void |
setInputDimension(int numDim)
Sets the number of dimensions of this distribution |
void |
setMean(cern.colt.matrix.DoubleMatrix1D mean)
Sets the mean of this distribution. |
void |
setSeed(int seed)
Sets the seed for the random number generator of this distribution instance. |
| Methods inherited from class distribution.BasicMultivariateDistribution |
|---|
densityAt, densityAt, densityAt, getInputDimension, makeNextSample, makeNextSample, nextSample, nextSample |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MultivariateNormal()
| Method Detail |
|---|
public double densityAt(double[] x)
MultivariateDistribution
x - the given point.
public cern.colt.matrix.DoubleMatrix1D densityAt(cern.colt.matrix.DoubleMatrix2D x,
cern.colt.matrix.DoubleMatrix1D p)
MultivariateDistribution
densityAt in interface MultivariateDistributiondensityAt in class BasicMultivariateDistributionx - matrix whose rows are the points where density is desired.p - vector to hold the result, cannot be null.
public void nextSample(double[] arr)
MultivariateDistribution
arr - array to store the result, cannot be null.public cern.colt.matrix.DoubleMatrix2D nextSample(cern.colt.matrix.DoubleMatrix2D mat)
MultivariateDistributionm random samples of this distribution and places
the result in the supplied matrix. Returns a pointer to the same matrix for
convenience.
nextSample in interface MultivariateDistributionnextSample in class BasicMultivariateDistributionmat - matrix to hold the result. Cannot be null
MultivariateDistribution.makeNextSample(int) to creates
samples from scratch.public void setCovariance(cern.colt.matrix.DoubleMatrix2D covariance)
covariance - the given covariance matrix.public void setInputDimension(int numDim)
MultivariateDistribution
setInputDimension in interface MultivariateDistributionsetInputDimension in class BasicMultivariateDistributionnumDim - the given number of dimensions.public void setMean(cern.colt.matrix.DoubleMatrix1D mean)
mean - the given mean.public void setSeed(int seed)
MultivariateDistribution
seed - the given seed.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||