Suppose I have $Z_n \sim \text{Bin}(n,p)$.

When I set up the joint probability distribution to calculate the maximum likelihood estimator, I am confused how the product should look like since each random variable $Z$ is now a function of $n$, which coincides with the parameter $n$ in the binomial distribution.

I know the final answer should be $\hat{p}_n = Z_n / n$.

Could you please help me? thanks!

  • $\begingroup$ Hi @user123276, let me know if i've accidentally changed your question. $\endgroup$ – BlackAdder Jan 24 '14 at 9:00
  • $\begingroup$ Are you supposed to find the MLE of $p$ based on only one observation $Z_n$ with $n$ being fixed? $\endgroup$ – Stefan Hansen Jan 24 '14 at 10:31
  • $\begingroup$ Usually in this sort of question, the parameter $n$ is known while the parameter $p$ is being estimated. $\endgroup$ – Henry Jan 24 '14 at 13:03

As Henry said, you will typically know $n$, you will also know the number of successes, $x$, hence your likelihood will look like this:${n\choose x} p^x(1-p)^{n-x}$. You want to optimize this wrt $p$ holding $x$ and $n$ constant. To simplify this problem, you can ignore the combinatorial factor at the front, as it is not affected by $p$. Taking the logarithm of the remaining factors will make our problem a little easier, giving us the loglikelihood:


Take the derivative of this wrt $p$ and set to 0:

$0= \frac{x}{p}-\frac{n-x}{1-p}\rightarrow \frac{x}{p}=\frac{n-x}{1-p}\rightarrow \frac{1-p}{p}=\frac{n-x}{x}\rightarrow \frac{1}{p}=\frac{n}{x}\rightarrow \hat p=\frac{x}{n}$

So, the value of $p$ that maximizes the likelihood of your data is the intuitive estimator: the number of successes divided by the total number of trials.

| cite | improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.