[R] Help with pexp( )

Jeann S jeann_123 at hotmail.com
Wed Apr 11 21:45:42 CEST 2007

Hi Douglas,

Thank you very much.

Why I need the exact value is that I need apply qnorm() after. If it pexp() 
gives 1, then qnorm produces "Inf".

Your suggestion is very helpful. In my case, I'll jsut simply use 
-qnorm(pexp(..., lower.tail=FALSE)).

All the best,


>From: "Douglas Bates" <bates at stat.wisc.edu>
>To: "Jeann S" <jeann_123 at hotmail.com>
>CC: R-help at stat.math.ethz.ch
>Subject: Re: [R] Help with pexp( )
>Date: Wed, 11 Apr 2007 14:14:17 -0500
>On 4/11/07, Jeann S <jeann_123 at hotmail.com> wrote:
>>Dear all,
>>Sorry for bringing up an old issue:
>>     >pexp(50, 0.5)
>>     [1] 1
>>In some cases, pexp()  gives CDF=1. I read some discussion in 2002 saying 
>>has been patched. However it's not working in "R2.4.1Patched". Could 
>>help me out?
>And why is this a problem?  The cdf of an exponential distribution
>with rate = 0.5 evaluated at x = 50 is very close to 1.  If you want
>to find out exactly how close you could use
>pexp(50, rate = 0.5, lower.tail = FALSE)
>which gives an answer on the order of 10^(-11).

Find the best places on campus to get take out, study & unwind

More information about the R-help mailing list