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

Home » Public Forums » archive » Re: gamma random numbers ?
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: gamma random numbers ? [message #30730] Wed, 15 May 2002 15:43 Go to previous message
Craig Markwardt is currently offline  Craig Markwardt
Messages: 1869
Registered: November 1996
Senior Member
hkc@ariel.met.tamu.edu (hkc) writes:

> i tried to make a gamma random numbers generator with two variables,
> shape and scale parameters.
> my simple idea is to use a uniformly distributed random number
> generators in IDL.
> then the probability of each bins is set to be distribuited by gamma
> functions.
> it means that inside of each bins, data are distributed uniformly,
> but overall probability is distributed by gamma.
> do you think it is O.K.?
> please let me know if you have any ides for this.
> thanks

This is the second time you have asked the same question, but I made a
response the first time. I'll assume you missed it. Or, did this
response not help?

Craig Markwardt writes:
>
> I think you just multiply the deviate by the scale parameter, right?
>
> See beautiful on-line book here:
> http://www.itl.nist.gov/div898/handbook/eda/section3/eda366b .htm

I.e.,

r = randomu(seed, gamma=SHAPE)*SCALE

Craig


--
------------------------------------------------------------ --------------
Craig B. Markwardt, Ph.D. EMAIL: craigmnet@cow.physics.wisc.edu
Astrophysics, IDL, Finance, Derivatives | Remove "net" for better response
------------------------------------------------------------ --------------
[Message index]
 
Read Message
Read Message
Previous Topic: Re: resizing idlde editor windows? (was: Re: how i can detect round bright structures in picture??)
Next Topic: Re: reversing [near, far] for volume rendering

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

Current Time: Fri Oct 10 15:49:43 PDT 2025

Total time taken to generate the page: 0.95721 seconds