help on sampling from the truncated normal/gamma distribution on the far end (probability is very low)

5 messages
Open this post in threaded view
|

help on sampling from the truncated normal/gamma distribution on the far end (probability is very low)

 Hi, guys, I am trying to sample from a truncated normal/gamma distribution. But only the far end of the distribution (where the probability is very low) is left. e.g. mu = - 4; sigma = 0.1; The distribution is Normal(mu,sigma^2) truncated on [0,+Inf]; How can I get a sample? I tried to use inverse CDF method, but got Inf as answers. Please help me out. Also, pls help me on the similar situation on gamma dist'n. Thanks, Sonia         [[alternative HTML version deleted]] ______________________________________________ [hidden email] mailing list https://stat.ethz.ch/mailman/listinfo/r-helpPLEASE do read the posting guide http://www.R-project.org/posting-guide.htmland provide commented, minimal, self-contained, reproducible code.
Open this post in threaded view
|

Re: help on sampling from the truncated normal/gamma distribution on the far end (probability is very low)

 Hi Sonia, If I did not make a mistake, the conditional distribution of X given that X > 0 is very close to exponential distribution with parameter lambda = 40, so you can sample from this distribution. --- On Mon, 15/9/08, Daniel Davis <[hidden email]> wrote: > From: Daniel Davis <[hidden email]> > Subject: [R] help on sampling from the truncated normal/gamma distribution on the far end (probability is very low) > To: [hidden email] > Received: Monday, 15 September, 2008, 2:28 PM > Hi, guys, > > I am trying to sample from a truncated normal/gamma > distribution. > But only the far end of the distribution (where the > probability is very low) > is left. e.g. > > mu = - 4; > sigma = 0.1; > The distribution is Normal(mu,sigma^2) truncated on > [0,+Inf]; > > How can I get a sample? I tried to use inverse CDF method, > but got Inf as > answers. Please help me out. > > Also, pls help me on the similar situation on gamma > dist'n. > > > Thanks, > Sonia > > [[alternative HTML version deleted]] > > ______________________________________________ > [hidden email] mailing list > https://stat.ethz.ch/mailman/listinfo/r-help> PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html> and provide commented, minimal, self-contained, > reproducible code. ______________________________________________ [hidden email] mailing list https://stat.ethz.ch/mailman/listinfo/r-helpPLEASE do read the posting guide http://www.R-project.org/posting-guide.htmland provide commented, minimal, self-contained, reproducible code.
Open this post in threaded view
|