My problem is that given a dataset, I want to program fitting a [gamma distribution](http://en.wikipedia.org/wiki/Gamma_distribution) on this data by estimating the two parameters(shape and the scale parameters) using Maximum Likelihood Estimation. I checked [wikipedia](http://en.wikipedia.org/wiki/Gamma_distribution#Maximum_likelihood_estimation) article on MLP estimation of Gamma Distribution but it is not obvious there how we can have two equations where we can have the MLP estimate of the shape and the scale parameters and more importantly how to program them?



maximum likelihood of gamma distribution computer calculation
The answer is [on the Wikipedia page](http://en.wikipedia.org/wiki/Gamma_distribution#Maximum_likelihood_estimation).
There is not a closed form solution so you have to use an iterative method like the one they have provided.


