. Use the data from HTable.pdf to estimate alpha and beta. 1.691 1.437 8.221 5.9
ID: 2907866 • Letter: #
Question
. Use the data from HTable.pdf to estimate alpha and beta.
1.691 1.437 8.221 5.976 1.116 4.435 2.345 1.782 3.810 4.589 5.313 10.900 2.649 2.432 1.581 2.432 1.843 2.466 2.833 2.361 914691 6. 677778 8. , 8 8 9 9 9 9 0 0 0 0 1 1 1 1 2 2 2 57 20 22 25 8899 1222 146914 3. 3 3 3 3 3 3 4 4 4 4 4 4 4 4 4 4 5 5 5 5 5 6 6 40 60 80 00 20 40 60 80 00 20 40 60 80 00 20 40 60 555556 2 0000111 2 T-10 20 30 40 50 60 70 80 90 00 3 3 30 40 50 60 70 80 90 .00 222222222333333333344444 05 12 19 26 33 40 47 9 00000 0. res T-001 002 0.0 oga ous 006 0.0 THX | 08 09 0.1 0.1 0.1 0.1 0.1 0.1 0.1 17 18 19 20 30 40 50 60 010 80 90 100 110 120 130 PAH 00 0. 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1Explanation / Answer
We known that the MLE of gamma distribution is not coming in a closed form sothatone can use any iteration method to estimate the parameter of gamma distribution. Here I use nlm command to estimate the parameter in R and the code is given below.
x=c(1.691,1.437,8.221,5.976,1.116,4.435,2.345,1.782,3.810,4.589,5.313,10.90,2.649,2.432,1.581,2.432,1.843,2.466,2.83)
n=length(x)
Fx6=function(x,theta,al){pgamma(x, al,theta)}
fx6=function(x,theta,al){(theta^al/gamma(al))*(x^(al-1))*exp(-x*theta)}
### Gamma Distribution #############
LogL6=function(th){
theta=th[1]; al=th[2]
z6=n*al*log(theta)+(al-1)*sum(log(x))-theta*sum(x)-n*log(gamma(al))
return(-z6)
}
M6=nlm(LogL6, c(2,2), hessian=T)
Beta=M6$estimate[1];
Beta
Alpha=M6$estimate[2];
Alpha
Result
Beta=M6$estimate[1];
> Beta
[1] 0.7648101
> Alpha=M6$estimate[2];
> Alpha
[1] 2.731098
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.