13

I am trying to check statement on p. 23 of Data Analysis Using Regression and Multilevel/Hierarchical Models

For example, consider two independent studies with effect estimates and standard errors of 25 ± 10 and 10 ± 10. The first study is statistically significant at the 1% level

in R

> estimate <- 25
> se <- 10
> z <- estimate / se
> z
[1] 2.5

t distribution converges to normal as sample size increases (Cassella Berger 2ed Exercise 5.18)

I then plug z to distribution function to get probability of observing any value equal to |z| or larger (p value) ISL p. 67

> pnorm(2.5, lower.tail=FALSE)
[1] 0.006209665

Whereas if I use formula from method [3]

> exp(-0.717 * z - 0.416 * z * z)
[1] 0.01236977

Was 0.0062 due to poor approximation? Or it should not compute that way?

[3]: Lin J-T. Approximating the normal tail probability and its inverse for use on a pocket calculator. Appl Stat1989;38:69-70.

wildfluss
  • 131
  • 1
  • 1
  • 3
  • 3
    The approximation looks excellent to me: 0.01236977 is extremely close to twice 0.006209665. The error is only 0.4%. By the way, the approximation is the calculation of "method [3]", not pnorm! – whuber Nov 23 '17 at 15:00
  • 2
    @whuber thank you! I should have multiplied pnorm by 2 because equal to or larger |z| means two intervals ? oh, so pnorm is by definition calculation ? – wildfluss Nov 23 '17 at 15:09
  • If you're unsure what pnorm does, the first place to look is its help page, accessed via the command ?pnorm. If that's unclear--which is often the case, because many R help pages are overly terse--then experiment with it. For instance, you can plot it easily with curve(pnorm(x), -3, 3). – whuber Nov 24 '17 at 13:20

0 Answers0