# How to find MLE, probability distribution, and bias?

Suppose the data consist of a single number $$X$$, from the following probability density:

$$f(x|θ) = \begin{cases} \frac{1+xθ}{2} & & \text{for } -1 \leqslant x \leqslant 1, \\[6pt] 0 & & \text{otherwise}, \end{cases}$$

where $$-1 \leqslant \theta \leqslant 1$$. Find the maximum likelihood estimate (MLE) $$\hat{\theta}$$ of the parameter $$\theta$$ and find its (exact) probability distribution. Is the MLE unbiased? Find its bias and MSE. [Hint: First find the MLE for a few sample values of $$X$$; that should suggest to you the general solution. Drawing a graph helps! The distribution of the MLE will of course depend upon $$\theta$$.]

How do I begin?

Begin with the hint given. Take $$x=0.3$$. Can you find the value of $$\theta\in[-1,1]$$ that maximizes $$\frac{1+0.3\theta}{2}$$?

Take $$x=0.8$$. Can you find the value of $$\theta\in[-1,1]$$ that maximizes $$\frac{1+0.8\theta}{2}$$?

Take $$x=-0.5$$. Can you find the value of $$\theta\in[-1,1]$$ that maximizes $$\frac{1-0.5\theta}{2}$$?

Take $$x=-0.9$$. Can you find the value of $$\theta\in[-1,1]$$ that maximizes $$\frac{1-0.9\theta}{2}$$?

The first step of finding the MLE is to write out the likelihood function (or log-likelihood function). In the present problem, with only a single observed data point, the latter is given by:

$$\ell_x(\theta) = \ln(1 + x \theta) + \text{const.} \quad \quad \quad \text{for } -1 \leqslant \theta \leqslant 1.$$

This is the function you need to maximise to obtain the MLE. Maximising this function is a univariate calculus problem, which will require you to derive the first and second derivatives of the function. By maximising this function you will obtain the MLE as a function of the observed data value $$x$$, and you can then proceed to the next parts of the question. (In this case, you will see that the maximising value is a "boundary solution" to the problem.)