comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Generation of another Gaussian random variable from a given one...
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Generation of another Gaussian random variable from a given one... [message #94135 is a reply to message #94134] Fri, 27 January 2017 20:54 Go to previous messageGo to previous message
Jim  Pendleton is currently offline  Jim Pendleton
Messages: 165
Registered: November 2011
Senior Member
On Friday, January 27, 2017 at 9:29:50 PM UTC-7, dave poreh wrote:
> On Saturday, January 28, 2017 at 7:45:38 AM UTC+3:30, dave poreh wrote:
>> Folks,
>> I have a Gaussian random variable with zero mean, and variance (f_x). I need to generate another Gaussian random variable with zero mean, and another variance, that would be correlated with the first one (f_x) with the correlation coefficient of say *r*.
>> I need some suggestions...
>> Thanks for any kind of helps in advances,
>> Cheers,
>> Dave
>
> ... I mean at the end we should have:
> corr(f_x, f_y) = r
> The correlation between two Gaussian random variable with zero mean, and variance should be = r

If no IDL solution is quickly forthcoming, there's a similar discussion on stackexchange.com, with an algorithmic description. http://stats.stackexchange.com/questions/15011

An implementation is provided in R. I'm no expert on R syntax, but it looks like the code could be translated from R to IDL.

For validation of an IDL implementation against this reference, you could call R directly via python and the rpy2 bridge.

http://www.harrisgeospatial.com/Company/PressRoom/Blogs/IDLD ataPointDetail/TabId/902/ArtMID/2926/ArticleID/14718/Calling -the-R-Statistical-Package-from-IDL-via-Python.aspx

Jim P.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: GDL 0.9.7 delivered
Next Topic: How to make long program keep going if error comes??

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sat Oct 11 12:43:26 PDT 2025

Total time taken to generate the page: 0.00240 seconds