Hello community first of all thanks for helping me with my math problems. Here I'm again with hypothesis test exercise. I want to know if I made some mistake in my answer and if someone can help me to calculate the value $p$ for the problem, (I'm not sure how to do it). Thank you so much!
Problem statement:
Karl conducted an experiment to study whether honey bees have color vision. He trained bees to feed on a dish of sugar water that was set on a colored card. Later he set the colored card (without the sugar water) onto an array of four cards colored in grey. The experiment was repeated with the colored tile in different positions on the array. Of $27$ incoming bees who landed on a tile, twelve landed first on the colored tile.
- i) Define the population and sample involved in this experiment. Explain how this experiment can be used to test whether bees have color vision.
- ii) Define a parameter of interest and state a null hypothesis and alternative hypothesis involving this parameter. Hint: If bees could not see in color, what proportion of incoming bees would you expect to first land on the blue card? If you are using symbols, define what they represent.
- iii) Conduct a statistical hypothesis test to answer the question whether bees can see in color (at significance level $\alpha= 0.05$). Report the $p$-value of your test together with a conclusion sentence. Show your work.
My work:
i)
Because the bees are incentives with (I suppose $4$ dish with water) and the one with sugar was blue, then Karl must to change the position of the blue dish for making sure the bees don’t use their memory if they have it. After some time, he can take away the water and leave the blue card, with the others gray cards, knowing the proportion of the bees landed in the blue card, compared with the others gray cards. He can inferred that bees can distinguises blue over gray, because the only difference among the cards are the color, and no other sense is involve he can conclude bees are not color blind.
Population: All honeybees fed with the dish of sugar water that was set on the colored card varying the position.
Sample: $27$ incoming honeybees fed with the dish of sugar water that was set on the colored card, which landed on a tile.
ii)
Parameter of interest: proportion of bees that land first in the blue tail
$\mathbf{H_0:}$ The proportion of bees land first in a blue tail is equal to the proportion of bees landed first in other card. That means that bees are color blind (Extra: also it is possible they has no memory at all, that why he change position to discard such possibility)
$\mathbf{H_a:}$ If the proportion of bees that first landed in blue car is greater than the bees landed first in other card then bees aren’t color blind. It can differentiate blue color from others (at least one more color).
iii)
$P=12/27$ (bees land first in blue card) $Q=1-12/27$ (in other card in the example 3)
Sample size $=27$ Significance level $= 0.05$
Because is a small sample I use $t$ distribution. df $=27-1$ $\alpha=0.025/2$
Test statistic $= p \pm t\sqrt{pq/n}$
Questions:
Part i
It is correct my answer? If not what or where is my mistakes.
Part ii
It is correct my answer? If not what or where is my mistakes.
Part iii
1) How to compute the $p$ value, in this case? I need help in this part.
2) My answer for part iii. second question, if I know $p$, then if the $p$ value is smaller than the significance level of $0.05$ then I reject $H_0$ and I accept $H_a$, honey bees can see blue color.
Edited slightly, per clarification in OP comment.
Under the null hypothesis that bees can distinguish red from various shades of grey, the probability of landing first on blue would be 1/4 (one blue card out of four cards altogether). So the null distribution of the number $X$ landing first on the blue card out of $N = 27$ (presumably independently acting) bees would be $X \sim Binom(N = 27, p = 1/4)$.
Under the null hypothesis, you would see on average $E(X) = Np = 27(1/4) = 6.75$ bees landing first on blue. You want to reject if $X$ is significantly greater than expected. The p-value (of this right-tailed test) for your particular data is defined as $P(X \ge 12)$ when $X \sim Binom(27, 1/4).$ You can use the binomial formula, binomial tables, or software to find this probability, or (approximately) by using a normal approximation. Using R software, I got the answer below:
So the p-value is $2.16\%,$ which is well below 5%, and you would say results are significant at the 5% level.
I suppose this gives you most of what you need, and will let you formulate the rest of the answers for yourself.
At the risk of 'overthinking' I would worry that some scent of sugar might have clung to the blue card from the first step of the experiment. Maybe I would use a different blue card from the same card stock as the first, and placed along with the grey cards by someone who has not been sneaking a taste of the sugar.
Also, your 'test statistic' looks more like an attempted confidence interval.
The figure below shows probabilities that sum to the p-value in red. The p-value can be roughly approximated by the area (1.74%) under the normal curve to the right of the dotted line.
Addendum: Code for figure (as requested in Comment):