For example suppose i am given a data set X∈Rn which is basically a bunch of data points and I wanted to determine what the distribution mean is. I would then consider which is the most likely value based on what I know. If I assume the data comes from the normal distribution N(μ,σ2) with μ as the mean and σ2 as the variance then we have f(X∣μ,σ2)=n∏i1√2πσ2e−12σ2(xi−μ)2.
If μ is not known then I would try to estimate it by way of maximum likelihood or using the equation I would state
l(μ∣X,σ2)=n∏i1√2πσ2e−12σ2(xi−μ)2
Here the equation is the same but the paramter of interest is μ. To solve we take the derivative, set it equal to 0 and solve for μ so we have.
∂∂μn∏i1√2πσ2e−12σ2(xi−μ)2
However before doing so I see that I can apply the natural log before finding the derivative to solve for x and simplify the equation thus ...
ln(l(μ∣X,σ2))=n∑iln(1√2πσ2)−12σ2(xi−μ)2
∂∂μn∑iln(1√2πσ2)−12σ2(xi−μ)2
=1σ2n∑i(xi−μ)=0
=1σ2n∑ixi=1σ2n∑iμ
=n∑ixi=n⋅μ
=1nn∑ixi=μ
so an approximation of μ would be the average of the data or ¯x=1nn∑ixi.
Using MLE we can also find out what the estimated standard deviation is.