public class Wishart extends Object
Based on method in Odell and Feiveson JASA 1966 p.199-203
The interface is modeled after ContinuousDistribution from colt, which unfortunately is designed only for univariate distributions.
Constructor and Description |
---|
Wishart(double df,
cern.colt.matrix.DoubleMatrix2D covariance,
cern.jet.random.engine.RandomEngine randomGenerator) |
Modifier and Type | Method and Description |
---|---|
cern.colt.matrix.DoubleMatrix2D |
nextDoubleMatrix()
Based on R code from Francesca Dominici, http
://www.biostat.jhsph.edu/~fdominic/teaching/BM/bm.html
Returns
w=(RU)'RU
where
Cov=U'U (U is upper triang)
and where upper-tri R is
R_ij˜N(0,1), i<j ; (R_ii)ˆ2˜Chisq(nu-s+i)
|
public Wishart(double df, cern.colt.matrix.DoubleMatrix2D covariance, cern.jet.random.engine.RandomEngine randomGenerator)
s
- df
- covariance
- randomGenerator
- public cern.colt.matrix.DoubleMatrix2D nextDoubleMatrix()
Returns
w=(RU)'RUwhere
Cov=U'U (U is upper triang)and where upper-tri R is
R_ij˜N(0,1), i<j ; (R_ii)ˆ2˜Chisq(nu-s+i)
s
- nu
- covariance
- Copyright © 2003–2022 UBC Michael Smith Laboratories. All rights reserved.