1

Let $X_i$ ($i=1,\dots, n$) be a random sample from $X\sim \exp(\lambda_1)$ and $Y_j$ ($j=1,\dots, m$) be a random sample from $Y\sim \exp(\lambda_2)$, and $X$ and $Y$ be independent. I try to find the generalized test of $H_0: \lambda_1=\lambda_2$ v.s. $H_1: \lambda_1\neq \lambda_2$. Find the distribution of the statistic and the critical region of the generalized test at level $\alpha$.


My work: The likelihood function is that for $\theta=(\lambda_1, \lambda_2)$ $$ L(\theta)=\lambda_1^n\lambda_2^m \exp(-n\lambda_1\bar{X}-m\lambda_2\bar{Y}) $$ where $\bar{X}$ and $\bar{Y}$ are sample mean.

Then I want to get the likelihood ratio statistic: \begin{align} \Lambda(x) &= \frac{\sup_{\theta=\theta_0}L(\theta\mid X)}{\sup_{\theta\neq\theta_0}L(\theta\mid X)} \end{align}

The global MLE are $\hat{\lambda}_1=\frac{1}{\bar{X}}$ and $\hat{\lambda}_2=\frac{1}{\bar{Y}}$. The restricted MLE for $\lambda_1=\lambda_2$ is $$\lambda_0=\frac{m+n}{n\bar{X}+m\bar{X}}$$

So we have $$ \Lambda=\frac{(m+n)^{m+n}}{n^nm^m}[\frac{n\bar{X}}{n\bar{X}+m\bar{Y}}]^n[1-\frac{n\bar{X}}{n\bar{X}+m\bar{Y}}]^m $$

So we take the statistic $$T=\frac{n\bar{X}}{n\bar{X}+m\bar{Y}}$$

So to find the critical region, we need $$\Lambda=CT^n(1-T)^m\le \lambda_0$$

From here, I am not sure how to solve that. It seems that $CT^n(1-T)^n$ is decreasing if $T\le n/(n+m)$ and increasing is $T\ge n/(m+n)$. (since $g'(T)=T^{n-1}(1-T)^{m-1}[n-(m+n)T]$)

So $\Lambda\le \lambda_0$ (we will reject $H_0$) is equivalent as $$c_1\le T\le c_2$$ for some constants $0<c_1<c_2$ and it satisfy $$c_1^n(1-c_1)^m=c_2^n(1-c_2)^m$$

For the test level $\alpha$, we also need $$ P(c_1\le T\le c_2)=\alpha $$ (the probability that we reject $H_0$).

The distribution of $T$: under $H_0$ we have $\sum X_i\sim Gamma(n,1/\lambda)$ and $\sum X_i+\sum Y_j\sim Gamma(n+m,1/\lambda)$. Then $$ \frac{m+n}{n}T\sim \frac{\chi^2(2n)/(2n)}{\chi^2(2(m+n))/(2(m+n))}\sim F(2n, 2(m+n)). $$

But what is the critical region?

Hermi
  • 1,480

1 Answers1

1

To test $H_0: \lambda_1=\lambda_2$ versus $H_1: \lambda_1\neq \lambda_2$, Instead the likelihood ratio tests you are using, you can use the following likelihood ratio test statistic defined by: $$ \Lambda =\frac{L(\lambda_1, \lambda_2)}{L((\hat{\lambda_1}, \hat{\lambda_2}))} \quad \text{(likelihood ratio test)} $$ where $L(\lambda_1, \lambda_2)$ is the likelihood function under the null hypothesis and $L(\hat{\lambda}_1, \hat{\lambda}_2)$ is the maximum likelihood estimate of the likelihood function.

For the exponential distribution, the likelihood function for a random sample $X_1,\dots,X_n$ with parameter $\lambda$ is given by: $$ L(\lambda) = \lambda^n e^{-\lambda \sum_{i=1}^{n}X_i} \quad \text{(Likelihood function)} $$ Using this likelihood function, we can write the likelihood ratio as:

\begin{align*} \Lambda &= \frac{L(\lambda_1, \lambda_2)}{L(\hat{\lambda}_1, \hat{\lambda}_2)}\\ &= \frac{\lambda_1^{n} \lambda_2^{m} e^{-(\lambda_1 \sum_{i=1}^{n}X_i + \lambda_2 \sum_{j=1}^{m}Y_j)}}{\hat{\lambda}_1^{n} \hat{\lambda}_2^{m} e^{-(\hat{\lambda}_1 \sum_{i=1}^{n}X_i + \hat{\lambda}_2 \sum_{j=1}^{m}Y_j)}}\\ &= \left(\frac{\lambda_1}{\hat{\lambda}_1}\right)^{n} \left(\frac{\lambda_2}{\hat{\lambda}_2}\right)^{m} e^{(\hat{\lambda}_1 - \lambda_1)\sum_{i=1}^{n}X_i + (\hat{\lambda}_2 - \lambda_2)\sum_{j=1}^{m}Y_j}. \end{align*} Under the null hypothesis $H_0: \lambda_1 = \lambda_2$, we have $\hat{\lambda}_1 = \hat{\lambda}_2 = \frac{n+m}{\sum_{i=1}^{n}X_i + \sum_{j=1}^{m}Y_j}$, and the likelihood ratio simplifies to: $$ \Lambda = \left(\frac{\sum_{i=1}^{n}X_i + \sum_{j=1}^{m}Y_j}{n+m}\right)^{n+m} e^{-n-m}. $$ The distribution of the likelihood ratio $\Lambda$ under $H_0$ is approximately chi-squared with one degree of freedom, as $n+m$ becomes large. Therefore, we can reject the null hypothesis at level $\alpha$ if: $$ \Lambda \leq \chi_{1,\alpha}^2 $$ where $\chi_{1,\alpha}^2$ is the $(1-\alpha)$ percentile of the chi-squared distribution with one degree of freedom.

Zbigniew
  • 805