Re: random points with a given dsitribution in rectangle
- From: "Ken Davis" <ken.davis@xxxxxxxxxx>
- Date: Tue, 14 Mar 2006 10:36:55 -0500
"clausvcm" <clausvcm@xxxxxxxxxxx> wrote in message
news:1142349258.652163.269240@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
ups! I didn't know what you say in point 1). The the question is how to
do that?
...I don't understand 2), I am simply discarding any points outside the
box (acept - reject)
and for 3) the box is just a limited space where I wish to generate
points inside. I imagined that I could get the box as I said in the
last post, but probably I am wrong.
ok, well, probably all this is because I started following my empirical
thinking and after what you say I was walking in the wrong direction.
So, how can i do the things correctly?. I re-state: with a covmatrix
and a mean vector how to generate gaussian points in a box, where the
dimensions of the box is obtained from the covmatrix (and here now I am
not sure I have been done it right :( )
Thanks
Gaussian variates will not necessarily fit in a rectangle. The Gaussian
distribution is infinite in extent. If you throw away samples then the
result is no longer Gaussian. That being said, samples from an uncorrelated
bivariate Gaussian distribution can be obtained by using (possibly scaled)
results from randn for each coordinate. Samples from an correlated bivariate
Gaussian distribution can be obtained by using mvnrnd from the statistics
toolbox. If you dont have that toolbox then there are some simple tricks
using matrix decompositions that I've seen in this newsgroup, but I don't
remember. Perhaps someone else will chime in here.
.
- Follow-Ups:
- Re: random points with a given dsitribution in rectangle
- From: clausvcm
- Re: random points with a given dsitribution in rectangle
- References:
- random points with a given dsitribution in rectangle
- From: clausvcm
- Re: random points with a given dsitribution in rec
- From: Fred
- Re: random points with a given dsitribution in rec
- From: clausvcm
- Re: random points with a given dsitribution in rec
- From: Fred
- Re: random points with a given dsitribution in rec
- From: clausvcm
- random points with a given dsitribution in rectangle
- Prev by Date: Re: robust multivariate linear regression?
- Next by Date: Re: Menu in English
- Previous by thread: Re: random points with a given dsitribution in rec
- Next by thread: Re: random points with a given dsitribution in rectangle
- Index(es):
Relevant Pages
|