Likelihood of a Uniform Distribution

514 Views Asked by At

I have been looking at this solution for two days and still can't understand the solution. The question is as follows:

Given $w[i], i = 1, 2, \ldots, N$ are IID following a distribution of $U[0, \theta]$, show that the regularity condition does not hold and hence the Cramer Rao bound cannot be applied to the problem.

My solution first states to let $$w[i] = x[i]$$ Where $x[i] \sim U(0, \theta)$ and $i=1, 2, \ldots, N$

Now, I need to find the log-likelihood of the function so first, let $\textbf{A} = \begin{bmatrix} x[1]\space x[2]\space\ldots\space x[N] \end{bmatrix}^T $

The answer key stated that $$ p(x[i];\theta) = \frac 1 \theta (u(x[i]) - u(x[i] - \theta)) $$ where $u(x) = 1 $ when $x>0$ and $u(x)=0$ when $x<0$.

Why is the last sentence so? Is it because I could express the Uniform distribution as a function of a Step function?

1

There are 1 best solutions below

1
On BEST ANSWER

The density of the uniform distribution is $$ f(x) = \begin{cases} 0 & \text{if }x<0\text{ or }x>\theta, \\[6pt] 1/\theta & \text{if } 0<x<\theta. \end{cases} $$ (Its exact values at $x=0$ and at $x=\theta$ don't matter.)

Now look at $\frac1\theta(u(x)-u(x-\theta))$.

If $x<0$ then $x-\theta<0$ (since $\theta>0$) so $u(x)$ and $u(x-\theta)$ are both $0$.

If $x>\theta$ then $x>0$ (since $\theta>0$) and $x-\theta>0$, so $u(x)$ and $u(x-\theta)$ are both $1$.

If $u(x)$ and $u(x-\theta)$ are both $0$, then $u(x)-u(x-\theta)$ is $0$.

If $u(x)$ and $u(x-\theta)$ are both $1$, then $u(x)-u(x-\theta)$ is $0$.

But now look at what happens if $0<x<\theta$. In that case $x>0$ and $x-\theta<0$, so $u(x)=1$ and $u(x-\theta)=0$. Therefore $u(x)-u(x-\theta)$ is $1$.

Conclusion: $$ u(x)-u(x-\theta) = \begin{cases} 0 & \text{if }x<0\text{ or }x>\theta, \\[6pt] 1 & \text{if }0<x<\theta. \end{cases} $$

Multiply that by $1/\theta$ and you have the density function as stated above.