Likelihood of Ordered Binomials

I have four numbers ($k_1 \dots k_4$) that come from 4 binomial trials with parameters $n$ and $\theta_1 \dots \theta_4$. I want to test (via likelihood ratio test) the hypotheses

$$H_0: \theta_1 = \theta_2 = \theta_3 = \theta_4$$ versus $$H_1: \theta_1 > \theta_2 > \theta_3 > \theta_4$$

I tried to calculate

$$P(k_1,k_2,k_3,k_4|\theta_1 =\dots = \theta_4 = \theta) =\int_0^1 \left(\prod_{i=1}^4\binom{n}{k_1}\theta^{k_i}(1-\theta)^{n-k_i}\right)d\theta$$

and

$$P(k_1,k_2,k_3,k_4|\theta_1 > \theta_2 > \theta_3 > \theta_4) = \int_0^1\binom{n}{k_1}\theta_1^{k_1}(1-\theta_1)^{n-k_1}\int_0^{\theta_1}\binom{n}{k_2}\theta_2^{k_2}(1-\theta_2)^{n-k_2}\int_0^{\theta_2}\binom{n}{k_3}\theta_3^{k_3}(1-\theta_3)^{n-k_3}\int_0^{\theta_3}\binom{n}{k_4}\theta_4^{k_4}(1-\theta_4)^{n-k_4}d\theta_4\dots d\theta_1$$

I.e., since the $\theta$s are ordered under the alternative hypothesis, I only consider each $\theta_i$ up to the value of its predecessor.

Using the values of $k_i = {8,7,5,4}$ and $n=12$, evaluating these expressions numerically seems to give me that the equality case has a higher probability. I would not expect this since the $k$s are ordered. Is there a problem with my expressions?

• Why are you integrating over $\theta$? With a likelihood ratio test, you would compare the two maximized likehoods $\max_{\theta} P(k_1, k_2, k_3, k_4|\theta_1 = \theta_2=\theta_3 = \theta_4)$ vs $\max_{\theta} P(k_1, k_2, k_3, k_4| \theta_1 > \theta_2>\theta_3>\theta_4)$ Jan 15, 2017 at 22:39
• I wanted to do the integration because I was interested in the probabilities. You are right that I don't need them explicitly to do the LRT. Thanks for pointing this out.
– user127156
Jan 16, 2017 at 1:58
• Isn't it intuitive, that when the null hypothesis allows for all frequencies to, at the least be equal, but the alternative orders them in the wrong direction, that the likelihood under the null should be correct? There are many violations of classical testing here. Jan 21, 2017 at 18:15

The integrals you described are not frequentist likelihood ratios, which involve maximizing over the unknown parameters given the constraints in the two models, but rather are akin to the Bayesian marginal likelihood $$P(x|\mathcal{M}_i) = \int P(x|\theta,\mathcal{M}_i) \pi(\theta|\mathcal{M}_i) d\theta$$ where $\mathcal{M}_i$, $i=0,1$ are the null and alternative models In the null case, implicitly there is a prior $\pi(\theta|\mathcal{M_0}) = 1$ hidden in the integral, which does indeed integrate to 1 over the unit hypercube $[0,1]^4$.