Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: How to generat Gamma random variables betwenn 0 and 1
Replies: 8   Last Post: Oct 10, 2013 3:26 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
Torsten

Posts: 1,450
Registered: 11/8/10
Re: How to generat Gamma random variables betwenn 0 and 1
Posted: Oct 9, 2013 5:22 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

"Zhou Yang" wrote in message <l331i1$n6o$1@newscl01ah.mathworks.com>...
> I can generate gamma random variable using GAMRND(A,B). I estimate A and B using PARMHAT = GAMFIT(X). I imported my data set from Excel to "X". The results give random variables with some values greater than 1. But I want to generate random variables between 0 and 1. Is it possible with "parmhat", if so what is the syntax?
> Thanks


I don't know the background of your question, but maybe you will have to estimate the parameters A and B of a truncated gamma distribution (truncated at x=1).
Generating random numbers of this distribution will result in values between 0 and 1.

Best wishes
Torsten.



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.