Here has the binomial distribution , so, up to a factor independent of , the likelihood function is
For , differentiating the log-likelihood gives
and the boundary cases give the same formula. Thus the binomial proportion maximum-likelihood estimator is