# Rejection Region for Likelihood Ratio Test

I have $$((Y_1,x_1),(Y_2,x_2),\ldots,(Y_n,x_n))$$ where $$Y_i$$ is distributed as $$N(\theta x_i,1)$$. I want to find the rejection region $$[0, c]$$ associated with $$\lambda$$ for a test with significance level $$\alpha$$. $$\lambda$$ is the log likelihood ratio for the test: $$H_0: \theta=\theta_0$$ or $$H_1: \theta\neq\theta_0$$. I have determined this to be $$-2\log \left(\frac{\exp (-\frac{1}{2}(\hat\theta-\theta_0)^2\sum x_i^2)}{\exp (-\frac{1}{2}(\hat\theta-\hat\theta)^2\sum x_i^2)}\right) = -2\log \left(\exp \left(-\frac{1}{2}(\hat\theta-\theta_0)^2\sum x_i^2\right)\right),$$ which simplifies to $$(\hat\theta-\theta_0)^2\sum x_i^2$$. In this equation, $$\hat\theta$$ denotes the maximum likelihood estimator, which I have determined to be $$\sum Y_ix_i/\sum x_i^2$$. My question is: How do I find the rejection region for this test? I know that I need to find $$\Pr((\hat\theta-\theta_0)^2\sum x_i^2 and solve this for $$c$$. The problem is that the expression does not follow a distribution, as far as I'm aware. How do I then determine the rejection region? Thanks in advance.

• The expression $(\hat\theta-\theta_0)^2\sum x_i^2$ is a function of only $Y$'s and constants. [Further, keep in mind that you're dealing with the case where $H_0$ is true here, so you know the distribution of the $Y$'s] – Glen_b Oct 16 '18 at 4:01
• Yes, but since this leads to $Pr(\sum Y_i x_i <(\sqrt{(c/\sum x_i^2}) + \theta_0)\sum x_i^2$, do I know the distribution of that? I cannot seem to find it. Whatever I try, I can't find a way to express it as $Pr(\sum Y_i < k^*)$. Either way, thanks for your help, I made progress at least. – user569579 Oct 16 '18 at 6:03
• You may want to see en.wikipedia.org/wiki/Wilks%27_theorem – Łukasz Grad Oct 16 '18 at 8:00
• @user569579 You have a linear combination of (presumably independent) Gaussians on the left. You can compute the distribution of $\sum Y_ix_i$ immediately. The stuff on the right is just some other constant, $c^\prime$. – Glen_b Oct 16 '18 at 23:02

If I simply take the likelihood ratio $$\Lambda$$ for testing $$H_0$$ versus $$H_1$$, I get

\begin{align} \Lambda(y_1,\ldots,y_n)&=\frac{\exp\left[-\frac{1}{2}\sum (y_i-\theta_0 x_i)^2\right]}{\exp\left[-\frac{1}{2}\sum (y_i-\hat\theta x_i)^2\right]} \\&=\exp\left[-\frac{1}{2}\left\{\theta_0\sum x_i^2-2\theta_0\sum x_iy_i-\hat\theta^2\sum x_i^2+2\hat\theta \sum x_iy_i\right\}\right] \\&=\exp\left[-\frac{1}{2}(\theta_0-\hat\theta)\left\{(\theta_0+\hat\theta)\sum x_i^2-2\sum x_iy_i\right\}\right] \end{align}

Putting the value of $$\hat\theta$$, I finally get

$$\Lambda(y_1,\ldots,y_n)=\exp\left[-\frac{1}{2\sum x_i^2}\left(\theta_0\sum x_i^2-\sum x_i y_i\right)^2\right]$$

So, for some positive $$k$$,

$$\Lambda(y_1,\ldots,y_n)k$$

Keeping in mind the level restriction, we need to find $$k$$ so that

$$P_{H_0}\left[\left|\theta_0\sum x_i^2-\sum x_i Y_i\right|>k\right]=\alpha$$

Or, $$P_{H_0}\left[\theta_0\sum x_i^2-\sum x_i Y_i>k\right]+P_{H_0}\left[\theta_0\sum x_i^2-\sum x_i Y_i<-k\right]=\alpha$$

I think all you need to note now is that for $$i=1,2,\ldots,n$$,

\begin{align} Y_i\stackrel{\text{ind}}{\sim}\mathcal N(\theta x_i,1)&\implies x_iY_i\stackrel{\text{ind}}{\sim}\mathcal N(\theta x_i^2,x_i^2) \\&\implies \sum_{i=1}^n x_i Y_i\stackrel{H_0}{\sim}\mathcal N\left(\theta_0\sum_{i=1}^n x_i^2,\sum_{i=1}^n x_i^2\right) \end{align}
{"ft_lang_label":"__label__en","ft_lang_prob":0.7286482,"math_prob":0.9999434,"size":3492,"snap":"2021-31-2021-39","text_gpt3_token_len":1309,"char_repetition_ratio":0.17115825,"word_repetition_ratio":0.014705882,"special_character_ratio":0.37371135,"punctuation_ratio":0.09292649,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":1.0000092,"pos_list":[0],"im_url_duplicate_count":[null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2021-07-24T23:14:39Z\",\"WARC-Record-ID\":\"<urn:uuid:eb14e122-3352-4080-9068-569f1ba34d9a>\",\"Content-Length\":\"169401\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:13b8c508-866a-4ea1-8932-ad92a3f460f7>\",\"WARC-Concurrent-To\":\"<urn:uuid:1757f02a-1d25-4898-b5be-cd6de9ea1b31>\",\"WARC-IP-Address\":\"151.101.1.69\",\"WARC-Target-URI\":\"https://stats.stackexchange.com/questions/372040/rejection-region-for-likelihood-ratio-test/372098\",\"WARC-Payload-Digest\":\"sha1:MJXLUYBVHYWUMWLR4TCFFRCIDKN4CWEN\",\"WARC-Block-Digest\":\"sha1:MLRDVGODI7DMQZWV2V2LXOP4OZ7XIZR2\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2021/CC-MAIN-2021-31/CC-MAIN-2021-31_segments_1627046151531.67_warc_CC-MAIN-20210724223025-20210725013025-00153.warc.gz\"}"}