Given $n=36$, $ p=20/36$, and $p_0=0.5$; calculate $p$-value

59 Views Asked by At

I know so far that:

$H_0:\ p= 0.5,$

$H_1:\ p> 0.5.$

And that $z$-score: $0.672$

I did $1-0.44 = 0.56$ for $p$-value but got it wrong, the correct answer is $0.2514$

2

There are 2 best solutions below

0
On BEST ANSWER

The correct z- score is

$$z=\Bigg(\frac{5}{9}-\frac{1}{2}\Bigg)12=\frac{2}{3}$$

Thus p-value is (using paper table)

$$\mathbb{P}[Z>0.67]=1-0.7486=0.2514$$

EDIT : I understood your error: you misread z table because you confused quantiles and probabilities; the numbers in the body of the table are probabilities while quantiles are in row+ column

0
On

Your question suggests that you are using an approximate binomial test, and @tommik's answer (+1) follows that lead.

[Often, one cannot expect more than about two place accuracy from normal approximations to binomial probabilities, especially after accounting for rounding errors from using printed tables. And here, a slightly better z-score would use a continuity correction: $z = (19.5/36 - .5)12 = 0.5333$ instead of the answer book's $z = 2/3.$ With continuity correction the P-value is approximately $0.297.$ The 'approved' normal approximation of the P-value turns out to be about $0.25$ as @tommik has shown. By contrast, the true binomial P-value is about $0.31,$ as shown below. In this problem the difference doesn't change the decision not to reject $H_0$ at the 5% level. However, in practical applications, it is best to use exact binomial P-values.]

The exact P value from observing $x = 20$ successes is $n = 36$ independent trials, under $H_0: p = 0.5.$ is $$P(X \ge 20\,|\,n=36, p=0.5) = 1 - P(X \le 19\,|\,n=36,p=0.5) = 0.3089,$$ from R:

1 - pbinom(19, 36, 0.5)
[1] 0.3088597

enter image description here

k = 0:36;  PDF = dbinom(k, 36, .5)
plot(k, PDF, type="h", lwd=3, col="blue")
 abline(h=0, col="green2");  abline(v=0, col="green2")
 abline(v = 19.5, col="red", lwd=2, lty="dotted")
 curve(dnorm(x, 18, 3), add=T, lwd=2)