This is the mail archive of the
gsl-discuss@sources.redhat.com
mailing list for the GSL project.
Re: covariance matrix data sampling
- From: Carsten Svaneborg <zqex at mpipks-dresden dot mpg dot de>
- To: gsl-discuss at sources dot redhat dot com
- Date: Sun, 7 Sep 2003 15:05:12 +0200
- Subject: Re: covariance matrix data sampling
- Organization: http://www.mpipks-dresden.mpg.de/~zqex
- References: <3F58FBED.2090200@pd.infn.it>
On Friday 05 September 2003 23:11, Pasquale Tricarico wrote:
> Now suppose that you want to generate, using a program based on the
> GSL, one million of data points using the covariance matrix.
Diagonalise the covariance matrix to get the eigenvalues and -vectors.
In the eigenspace of the covariance matrix, generate a 6D vector
with gaussianly distributed random numbers and where the
std deviations are given by 1/eigenvalue. (or just the eigenvalue??)
Then with a bit of linear algebra transform that vector back from the
eigenspace into the observables you use and translate to fix the mean.
By construction an ensemble of datapoints generated by that process
will reproduce the mean position and the covariance matrix, and each
data point will be statistically independent, which would not be the
case if a Monte Carlo technique was used to generate them.
--
Mvh. Carsten Svaneborg