[Math] uniformly most powerful test: binomial distribution

binomial distributionhypothesis testingprobabilitystatistical-inferencestatistics

Let $X$ $\sim \mathrm{Bin}(2,p)$ a binomial distributed random variable. Give a uniformly most powerful test with size $\alpha \in (0,1)$ for the hypotheses $H_0:p=\frac{1}{2}$ vs. $H_1:p=\frac{3}{4}$. Especially determine the critical value and the randomization constant.

Since "great" values of $X$ imply that the null hypotheses is not true, the test is constructed as a right tailed test.
So we have:
$\Theta=\{\frac{1}{2},\frac{3}{4}\}, \Theta_0=\{\frac{1}{2}\}, \Theta_1=\{\frac{3}{4}\}$

I know that

$\mathbb P(X\ge2)=\mathbb P(X=2)=\frac{1}{4}$

$\mathbb P(X\ge1)=1-\mathbb P(X=0)=\frac{3}{4}$

$\mathbb P(X\ge 0)=1$

Since there is no specific $\alpha$ given here, I have no idea what is actually to do here. I think that if f.e. $\alpha=0.3$, the critical value would be $2$ and if $\alpha=0.8$, the critical value would be $1$. Is that true?

Anyway, I don't know how to solve this task. Can anyone help me with that?

Best Answer

For the test with reject area $\{X\geq C\}$, if the critical value is $2$, then test size is $\mathbb P_{H_0}(X\geq 2)=\frac14\neq 0.3$. And for critical value $1$, the size is $\mathbb P_{H_0}(X\geq 1)=\frac34\neq 0.8$.

Note that if we consider the test with reject area $\{X\geq C\}$, then the size of this test can only be $0$, $1/4$, $3/4$ and $1$. If we want to construct the test with size $\alpha$ for any $\alpha\in(0,1)$, we should consider randomized test:

Always reject $H_0$ when $X>c$, always accept $H_0$ when $X <c$, and reject $H_0$ with a certain probability $p$ when $X=c$, where this probability is chosen to make the size of the test exactly $\alpha$.

The values of critical value $c$ and randomization probability $p$ are uniquelly determined by the equality $$ \alpha=\mathbb P_{H_0}(H_0 \textit{ is rejected}\,)=\mathbb P_{H_0}(X>c)+p\mathbb P_{H_0}(X=c). $$

This equation shows that we can restrict ourselves with $c\in\{0,1,2\}$ only. Then the first summand in this equation can be either $3/4$ or $1/4$ or $0$: $$\mathbb P_{H_0}(X>0)=3/4, \quad \mathbb P_{H_0}(X>1)=1/4, \quad \mathbb P_{H_0}(X>2)=0.$$

Say, let $\alpha=0.3\in(1/4,\,3/4)$. Then $c=1$ and randomization probability $p$ can be found as: $$ 0.3=\mathbb P_{H_0}(X>1)+p\mathbb P_{H_0}(X=1)=\frac14+p\cdot\frac12,\quad p=\frac{1}{10}. $$

More generally, for $\alpha\in(1/4,3/4)$ one need to take $c=1$ and then find that $p=2\alpha-\frac12$: $$ \alpha=\mathbb P_{H_0}(X>1)+p\mathbb P_{H_0}(X=1)=\frac14+p\cdot\frac12. $$

For $\alpha\in(0,1/4)$ we should take $c=2$ and the first summand $\mathbb P_{H_0}(X>2)$ equals zero. Then $$ \alpha=p \mathbb P_{H_0}(X=2) = p\cdot \frac14, \quad p=4\alpha. $$

Consider the last case $\alpha\in(3/4,1)$ and find $c$ and $p$.

Also look at $\alpha=1/4$ or $\alpha=3/4$. For this values the test does not need to be randomized. Really, the test with reject area $\{X\geq 2\}$ has the size exactly $\alpha=1/4$, and the test with reject area $\{X\geq 1\}$ has the size exactly $\alpha=3/4$. But both these tests are the variants of randomized tests with some $c$ and $p=0\vee 1$.

Related Question