MLE of β in the gamma distribution? So I have the pdf for the gamma distribution, $$f(x) = \frac{1}{\Gamma(\alpha)} \beta^\alpha x^{\alpha - 1} e^{-\beta x} $$ and I'm having trouble getting to the MLE of $\beta$, which should be $\frac{\alpha}{\overline{x}}$.  I keep messing up when it comes to taking the log but I'm not sure where.  Thanks!
 A: For a sample $\boldsymbol x = (x_1, \ldots, x_n)$ with observations $x_i \sim\operatorname{Gamma}(\alpha,\beta)$, where the shape $\alpha$ is known and the rate $\beta$ is unknown, we have the joint distribution $$f(\boldsymbol x \mid \alpha,\beta) = \prod_{i=1}^n f(x_i \mid \alpha,\beta) = \left( \frac{\beta^\alpha}{\Gamma(\alpha)} \right)^n \prod_{i=1}^n x_i^{\alpha-1} \exp(-\beta x_i) \propto \beta^{n \alpha} \exp\left(-\beta \sum_{i=1}^n x_i \right).$$  Note that we can justify removing all factors that are not functions of $\beta$ if we are interested in the likelihood of $\beta$ with respect to fixed $\boldsymbol x$ and $\alpha$.  Thus the log-likelihood of $\beta$ is proportional to $$\ell(\beta \mid \alpha, \boldsymbol x) \propto n \alpha \log \beta - \beta n \bar x \propto \alpha \log \beta - \bar x \beta.$$  The log-likelihood has critical points for $\beta$ satisfying $$0 = \frac{\partial \ell}{\partial \beta} = \frac{\alpha}{\beta} - \bar x,$$ therefore $$\hat \beta = \frac{\alpha}{\bar x}$$ is a critical point.  Since $\ell(\beta \mid \alpha,\boldsymbol x)$ is a strictly concave function (the second derivative is strictly negative for $\beta > 0$), it follows that the critical point $\hat \beta$ is a global maximum of the likelihood function and is therefore the MLE.

The key to calculating maximum likelihood estimators is to remove factors that are constant with respect to the parameter to be maximized.  This simplifies your calculation and reduces the possibility of an algebraic error.
