Difference between two statistical approaches to same question

55 Views Asked by At

Below I describe two approaches to the same hypothesis testing problem. Are these two approaches identical, such that one approach fails to reject the null if and only if the other one does?

Suppose you have some True/False question that you survey $50$ people about. 30 people answer correctly. Consider each response as a Bernoulli trial. Do you reject the null hypothesis that $p=0.5$?


Approach 1: Find the sampling distribution of $p_\text{hat}$ and check whether $p$ is in the 95% confidence interval of that sampling distribution:

$$E(p_\text{hat}) = \frac{30}{50} = 0.6, \text{ and } \sigma(p_\text{hat}) = \sqrt{\frac{p_\text{hat} (1-p_\text{hat})}{50}} = 0.07$$

> qnorm(0.025,.6,0.06928203)
[1] 0.4642097
> qnorm(0.975,.6,0.06928203)
[1] 0.7357903

Since $p$ is in $(0.46,0.73)$, fail to reject the null.


Approach 2:

Take $p = 0.5$ as a given, and find the probability of observing 30 or more successes. If this is less than 0.025, reject the null:

> 1-pbinom(29,50,.5)
[1] 0.101

Since this is not less than 0.025, do not reject the null.


1

There are 1 best solutions below

0
On BEST ANSWER

Not identical. The first one based on approximation, i.e., the sample distribution of $\hat{p}$ is only approximately normal for any finite $n$, while $n\hat{p}$ is exactly Binomial.