From tlumley at u.washington.edu  Thu Feb  7 22:04:58 2008
From: tlumley at u.washington.edu (Thomas Lumley)
Date: Thu, 7 Feb 2008 13:04:58 -0800 (PST)
Subject: [Rd] pnorm
In-Reply-To: <BAY127-W15EFA85D9E6F501736E0CFA52E0@phx.gbl>
References: <BAY127-W15EFA85D9E6F501736E0CFA52E0@phx.gbl>
Message-ID: <Pine.LNX.4.64.0802071300070.21946@homer22.u.washington.edu>

On Thu, 7 Feb 2008, jing hua zhao wrote:
>
> I calculated a two-sided p values according to 2*(1-pnorm(8.104474)), 
> which gives 4.440892e-16. However, it appears to be 5.30E-16 by a 
> colleague and 5.2974E-16 from SAS. I tried to get around with mvtnorm 
> package but it turns out to be using pnorm for univariate case. I should 
> have missed some earlier discussions, but for the moment is there any 
> short answer for a higher precision?

pnorm(8.104474,lower.tail=FALSE)*2 gives the same answer as SAS, and
pnorm(8.104474,lower.tail=FALSE,log=TRUE)/log(10)+log(2,10)
gives the (base-10) logarithm of the p-value, which is often the preferred 
genetics scale. These are much more accurate.


>					Somehow these days, statistical 
> geneticists are infatuated with such tiny p values!

Yes, but in my experience they are at least fairly realistic about the 
lack of difference between 4e-16 and 5e-16.

 	-thomas

Thomas Lumley			Assoc. Professor, Biostatistics
tlumley at u.washington.edu	University of Washington, Seattle



[Rd] pnorm
Thomas Lumley