Microsoft Word - 187-196   187    Ibn Al-Haitham Jour.for Pure&Appl.Sci. IHJPAS https://doi.org/10.30526/32.1.1914 Vol. 32 (1) 2019 Bayesian Estimation for Two Parameters of Gamma Distribution Under Precautionary Loss Function Loaiy F. Naji Department of Mathematics, Collage of Science, Mustansiriyah University, Baghdad, Iraq. louy.faeq@gmail.com Huda A. Rasheed Department of Mathematics, Collage of Science, Mustansiriyah University, Baghdad, Iraq. hudamath@uomustansiriyah.edu.iq   Article history: Received 29 July 2018, Accepted 26 November 2018, Publish January 2019 Abstract In the current study, the researchers have been obtained Bayes estimators for the shape and scale parameters of Gamma distribution under the precautionary loss function, assuming the priors, represented by Gamma and Exponential priors for the shape and scale parameters respectively. Moment, Maximum likelihood estimators and Lindley’s approximation have been used effectively in Bayesian estimation. Based on Monte Carlo simulation method, those estimators are compared depending on the mean squared errors (MSE’s). The results show that, the performance of Bayes estimator under precautionary loss function with Gamma and Exponential priors is better than other estimates in all cases. Keywords: Gamma distribution; Maximum likelihood estimator; precautionary loss function; Exponential prior; Lindley’s approximation. 1. Introduction The gamma distribution is extremely important in reliability analysis and life testing. Hogg and et al. (2013), showed that, the gamma distribution is not only a good model for waiting times, but one for many nonnegative random variables of the continuous type [1]. Also, it is a flexible distribution that commonly offers a good fit to any variable such as in environmental, meteorology, climatology and other physical situations [2]. The probability density function of the Gamma distribution is defined as follows [3] 𝑓 𝑥; α, β Γ ; x > 0 , α > 0 , β > 0 (1) Where, α and β are often called the shape and scale parameters, respectively. The Gamma function is Γ 𝛼 𝑥 𝑒 ∞ 𝑑𝑥 , for α 0 The cumulative distribution function (CDF) is F (𝑥; α, β) = Γ 𝑢 𝑒 𝑑𝑢   188    Ibn Al-Haitham Jour.for Pure&Appl.Sci. IHJPAS https://doi.org/10.30526/32.1.1914 Vol. 32 (1) 2019 This function is called incomplete Gamma function. The formula for the cumulative distribution can be written as F (𝑥; α, β) = 1 ∑ ! 𝑒 ∑ ! 𝑒∞ Therefore, the reliability functions for Γ 𝛼, 𝛽 is [3]: 𝑅 𝑥; α, β ∑ ! 𝑒 2. Estimation Methods In this paper, the moment estimators are used as primary estimators for maximum likelihood estimators of each of α and β.On the other hand, the maximum likelihood estimators are used as initial values for Bayesian estimators. 2.1. Moment Method Suppose that, X be a random variable has a Gamma distribution defined by (1). Let x1, x2, . . . , xn be a random sample of size n from X. Defining the first k sample moments about origin as 𝑚′ ∑ 𝑥` , r = 1, 2, . . . , k. The first k population moments about origin are given by 𝜇′ 𝐸 𝑋 . Now, equaling these moments, that is 𝜇 ′ 𝑚′ , r = 1, 2, . . . , k The solutions to the above equations denote by 𝜃^, 𝜃^, … , 𝜃^ , yields the moment estimators of θ1,θ2, . . . , θk [4] The moment method for estimating the two–parameter Gamma distribution can be derived as 𝑚 ∑ �̅� 𝑚 ∑ μ′ E X α β 𝜇′ 𝐸 𝑋 α β α β From 𝑚 𝜇′ , 𝑚 𝜇′ , we get 𝛼 ̅ ∑ ̅ (2) 𝛽 ̅ ∑ ̅ (3) 2.2. Maximum Likelihood Method The maximum likelihood method is one of the best methods of obtaining a point estimator of a parameter. This technique was proposed by R.A. Fisher (1912), and he developed it in 1920s [5].   189    Ibn Al-Haitham Jour.for Pure&Appl.Sci. IHJPAS https://doi.org/10.30526/32.1.1914 Vol. 32 (1) 2019 This method is the most popular procedure in estimating the parameter  which specifies a probability function f(x, 𝜃 , based on the observations 𝑥 , 𝑥 , … , 𝑥 which were independent sample from the distribution. The maximum likelihood estimator ^  of the parameter  which maximizes the likelihood function will be as follows [6] 𝐿 𝑥 , 𝑥 , … , 𝑥 ; 𝜃 𝜋 𝑓 𝑥 ; 𝜃 The likelihood function for two-parameter Gamma distribution is 𝐿 𝑥 , 𝑥 , … , 𝑥 ; 𝛼, 𝛽 Г 𝜋 𝑥 𝑒 ∑ (4) Taking the logarithm for (4), yields Ln L nlnГ α nαlnβ 𝛼 1 ∑ 𝑙𝑛𝑥 𝛽 ∑ 𝑥 The parameters that maximize the likelihood function are the solution of the equations = 𝑛𝛹 𝛼 𝑛𝑙𝑛𝛽 ∑ 𝑙𝑛𝑥 (5) ∑ 𝑥 (6) Observe that, the two equations (5) and (6) are difficult and complicated to solve, then it is impossible to find MLE for  and  analytically, we can use the numerical analysis (numerical procedure) to obtain and estimate  and  that maximize the likelihood function. One of these numerical procedures is Newton-Raphson method and using Hessian matrix, which is the second partial derivative of the log-likelihood function. We can construct Hessian matrix as follows [4] 𝑔 𝛼 𝑛Ψ(α) 𝑛𝑙𝑛𝛽 ∑ 𝑙𝑛𝑥 𝑔 𝛽 𝑛�̅� The partial derivatives of )(1 g with respect to unknown parameters  and  are 𝑛𝛹 𝛼 Where Ψ α is the derivative of Ψ α which is called as tri-gamma The partial derivatives of )(2 g with respect to unknown parameters  and  are Hence,                                )()( )()( 22 11 gg gg J k = 𝑎 𝑎 𝑎 𝑎 Where, Jk is the Jacobean matrix and Jk must be a non-singular symmetric matrix so, its inverse can be found as   190    Ibn Al-Haitham Jour.for Pure&Appl.Sci. IHJPAS https://doi.org/10.30526/32.1.1914 Vol. 32 (1) 2019 𝐽 | | 𝑎 𝑎 𝑎 𝑎                                    )( )( 2 1 1 1 1       g g J ik k k k k 𝛼 𝛽 𝛼 𝛽 1 𝑎 𝑎 𝑎 𝑎 ⎣ ⎢ ⎢ ⎢ ⎢ ⎡ 𝑛𝑎 𝛹 𝛼 𝑛𝑎 𝑙𝑛𝛽 𝑎 𝑙𝑛𝑥 𝑛𝑎 𝛼 𝛽 𝑛𝑎 �̅� 𝑛𝑎 𝛹 𝛼 𝑛𝑎 𝑙𝑛𝛽 𝑎 𝑙𝑛𝑥 𝑛𝑎 𝛼 𝛽 𝑛𝑎 �̅� ⎦ ⎥ ⎥ ⎥ ⎥ ⎤ The absolute value for the difference between the new value for  and  in new iterative value with previous value for  and  in last iterative represent the error term, it's symbol is  , which is a very small and assumed value. Then, error term is formulated as                                     k k k k k k       1 1 1 1 )( )( (7) Where k and k are the initial values for  and  respectively, for which are assumed. 3. Bayesian Estimation 3.1. Posterior Density Functions Using Gamma and Exponential Priors To estimate α and β parameters for Gamma distribution, we assume that α has a prior π1(ꞏ), which follows Gamma (a, b). At this moment we do not assume any specific prior on α. We simply assume that the prior on β is π2(ꞏ) and the density function of π2(ꞏ) is Exponential and it is independent of π1(ꞏ). 𝜋 𝛼 Г ; 𝑎 0, 𝑏 0, 𝛼 0 0 0. 𝑤 (8) 𝜋 𝛽 𝑐 𝑒 ; 𝑐 0, 𝛽 0 0 0. 𝑤 (9) The equations (8) and (9) are prior distribution for  and  respectively. The joint p.d.f is given by 𝐽 𝑥 , 𝑥 , … , 𝑥 ; 𝛼, 𝛽 𝐿 𝑥 , 𝑥 , … , 𝑥 ; 𝛼, 𝛽 𝜋 𝛼 𝜋 𝛽 Г 𝜋 𝑥 𝑒 ∑ Г 𝑐 𝑒 And the marginal p.d.f. of 𝑥 , 𝑥 , … , 𝑥 is given by 𝑓 𝑥 , 𝑥 , … , 𝑥 𝐿 𝑥 , 𝑥 , … , 𝑥 ; 𝛼, 𝛽 𝜋 𝛼 𝜋 𝛽 dα dβ ∞∞ Hence, the posterior density functions of  and  can be written as follows   191    Ibn Al-Haitham Jour.for Pure&Appl.Sci. IHJPAS https://doi.org/10.30526/32.1.1914 Vol. 32 (1) 2019 ℎ 𝛼, 𝛽|𝑥 , 𝑥 , … , 𝑥 𝐿 𝑥 , 𝑥 , … , 𝑥 ; 𝛼, 𝛽 𝜋 𝛼 𝜋 𝛽 𝐿 𝑥 , 𝑥 , … , 𝑥 ; 𝛼, 𝛽 𝜋 𝛼 𝜋 𝛽 dαdβ ∞∞ = Г ∑ Г Г ∑ Г ∞∞ 3.2. Bayes Estimator under Precautionary Loss Function Norstrom (1996) introduced an asymmetric precautionary loss function, which can be defined as follows [7] L θ, θ Based on precautionary loss function, risk function R θ, θ can be derived as follows R θ, θ E L θ, θ L θ, θ h θ x dθ ∞ 𝑅 𝜃, 𝜃 𝜃 𝜃 𝜃 ∞ h θ x dθ 𝜃 𝜃 h θ x dθ 2𝜃h θ x dθ ∞ 𝜃 ∞∞ h θ x dθ 𝑅 𝜃, 𝜃 E θ x 𝜃 2E θ x 𝜃 Taking the partial derivative for R θ, θ with respect to θ and setting it equal to zero, gives 𝜃 E θ x Hence, Bayes estimator relative to precautionary loss function, denoted by 𝜃 is given by 𝜃 E θ x (10) In general, 𝐸 u 𝛼, 𝛽 u 𝛼, 𝛽 ∞∞ h 𝛼, 𝛽|x , … x 𝑑𝛼𝑑𝛽 Where u(α,β) be any function for α and β. Therefore, 𝐸 u 𝛼, 𝛽 , ∞∞ , ,…, ; , , ,…, ; , ∞∞ i) Bayesian Estimation for the Shape Parameter α under Precautionary Loss Function To obtain Bayesian estimation for α, assume that, 𝑢 𝛼, 𝛽 𝛼   192    Ibn Al-Haitham Jour.for Pure&Appl.Sci. IHJPAS https://doi.org/10.30526/32.1.1914 Vol. 32 (1) 2019 Therefore, 𝐸 𝛼 𝑥 ∞∞ , ,…, ; , α β , ,…, ; , α β ∞∞ Notice that, it is difficult to find the solution of the ratio of two integrals. Therefore, Lindley's approximate will be used to get 𝐸 𝛼 𝑥 as follows 𝑢 𝛼, 𝛽 𝛼 u α,β 2𝛼 , u , 2 , u α,β 0 , u , = 0 𝜋 𝛼, 𝛽 Г 𝑐𝑒 𝑝 𝑙𝑛𝜋 𝛼, 𝛽 𝑎 1 𝑙𝑛𝛼 𝑎𝑙𝑛𝑏 𝑏𝛼 𝑙𝑛Г 𝛼 𝑙𝑛𝑐 𝑐𝛽 𝑝 𝑏 , 𝑝 𝑐 Recall that, Ln L (x1,…,xn ; α,β) = nα ln β-n ln Г(α)-β ∑ x α 1 ∑ ln x L12 = , β 𝑙 , 0 𝑙 , = 𝑙 , n Ψ" α σ Ψ′ α , 𝜎 𝐸 𝛼 𝛼 u 𝜎 𝑝 u 𝜎 𝑙 u 𝜎 𝑙 u 𝜎 𝜎 𝛼 2 Ψ′ 𝑏 2𝛼 Ψ′ n Ψ" 𝛼 Ψ′ Ψ′ 𝛼 Ψ′ 𝑏 Ψ" Ψ′ (11) Now, Substituting (11) into (10) yields, 𝛼 𝛼 Ψ′ 𝑏 Ψ" Ψ′ ii) Bayesian Estimation for the Scale Parameter β under Precautionary Loss Function Assume that, u α, β β then,   193    Ibn Al-Haitham Jour.for Pure&Appl.Sci. IHJPAS https://doi.org/10.30526/32.1.1914 Vol. 32 (1) 2019 u α,β 0 , u , = 0 , u α,β 2𝛽 , u , 2 Thus, 𝐸 𝛽 𝛽 u 𝜎 𝑝 u 𝜎 𝑙 u 𝜎 𝛽 𝑐 𝛽 (12) After Substituting (12) into (10) yields, 𝛽 𝛽 Where 𝛼 , 𝛽 are the maximum likelihood estimators for α, β respectively. 4. Simulation Study In this section, Monte – Carlo simulation is employed to compare the performance of three estimates (moment, Maximum likelihood and Bayes Estimators under precautionary loss function) for unknown shape and scale parameters based on the mean squared errors (MSE’s) as follows MSE(𝜃 = ∑ Where, I is the number of replications. We generated I = 3000 samples of size n = 20, 30, 50, and 100 to represent small, moderate and large sample sizes from Gamma distribution with α = 2, 3 and β = 0.5, 1. The values of α's prior parameters are chosen as a = 3, b = 3 and for β's prior parameter, c = 4. 5. Discussion and Conclusion The expected values and (MSE's) for estimating α and β are tabulated in Tables (1-8). The results of the Tables can be summarized by the following points 1. The performance of Bayes estimates under precautionary loss function for two parameters α and β are the best, since they give smallest mean square error, as indicated for all combinations of initial values of parameters. Followed by maximum-likelihood estimates, for all cases 2. It is clear that, the result for α (expected values and MSE's) at β = 0.5 are the same as the corresponding result when β = 1, the reason can be clarified easily, as follows According to moment method we have 𝛼 ̅ ∑ ̅ = ∑ 𝑥 (13) Note that, 𝑥 , 𝑥 , … , 𝑥 is a random sample from a Gamma distribution defined by (1), where each observation say 𝑥 is generated independently and identically by the following equation   194    Ibn Al-Haitham Jour.for Pure&Appl.Sci. IHJPAS https://doi.org/10.30526/32.1.1914 Vol. 32 (1) 2019 𝑥 ∑ log 𝑢 , i = 1, 2, …, n (14) Where, 𝑢 is a random number followed uniform distribution with (0,1), i.e., 𝑢 ~ 𝑈 0, 1 After substituting (14) into (13) yields, 𝛼 𝛽 𝑛 1 𝛽 log 𝑢 Therefore, 𝛽 will be canceled from moment estimation for 𝛼. Recall that, the moment is the initial value for MLE. Also Bayesian estimator are depending on MLE , So the result for expected values and MSE for 𝛼 are the same as the corresponding value of 𝛼 for different values of 𝛽. 3. It is observed that, MSE's of all estimators of shape parameter is increasing with the increase of the value of the shape parameter. Also, MSE values for all estimates are increasing with the increase of the scale parameter value in all cases. Table 1. The expected values for different estimators for unknown shape parameter α of Gamma distribution when α = 2 Method n 𝛼 𝛼 𝛼 β=0.5 β=1 β=0.5 β=1 β=0.5 β=1 20 2.486393 2.486393 2.33479 2.334791 2.14737 2.147371 30 2.298321 2.298321 2.194657 2.194658 2.085778 2.085778 50 2.183145 2.183145 2.118412 2.118412 2.058392 2.058392 100 2.090724 2.090724 2.055311 2.055311 2.027358 2.027357 Table 2. The expected values for different estimators for unknown shape parameter α of Gamma distribution when α = 3 Method n 𝛼 𝛼 𝛼 β=0.5 β=1 β=0.5 β=1 β=0.5 β=1 20 3.600494 3.600494 3.447432 3.447433 3.091556 3.091556 30 3.405721 3.405721 3.299321 3.299319 3.082031 3.08203 50 3.255532 3.405721 3.18809 3.299319 3.066335 3.08203 100 3.126059 3.126059 3.089527 3.089528 3.032201 3.032202 Table 3. The MSE values for different estimators for unknown shape parameter α of Gamma distribution when α = 2 Method n 𝛼 𝛼 𝛼 β=0.5 β=1 β=0.5 β=1 β=0.5 β=1 20 1.13161 1.13161 0.80765 0.80765 0.52387 0.52387 30 0.58915 0.58915 0.38833 0.38833 0.29354 0.29354 50 0.29714 0.29714 0.18510 0.18510 0.15579 0.15579 100 0.13609 0.13609 0.08313 0.08313 0.07647 0.07647   195    Ibn Al-Haitham Jour.for Pure&Appl.Sci. IHJPAS https://doi.org/10.30526/32.1.1914 Vol. 32 (1) 2019 Table 4. The MSE values for different estimators for unknown shape parameter α of Gamma distribution when α = 3 Method n 𝛼 𝛼 𝛼 β=0.5 β=1 β=0.5 β=1 β=0.5 β=1 20 2.06203 2.06203 1.62539 1.62540 1.02131 1.02132 30 1.11338 1.11338 0.84883 0.84883 0.62012 0.62012 50 0.61598 1.11338 0.44923 0.84883 0.37063 0.62012 100 0.25924 0.25924 0.18543 0.18543 0.16827 0.16827 Table 5. The expected values for different estimators for unknown scale parameter β of Gamma distribution when β = 0.5 Method n 𝛼 𝛼 𝛼 β=0.5 β=1 β=0.5 β=1 β=0.5 β=1 20 0.63802 0.61058 0.59870 0.58464 0.58620 0.57713 30 0.58456 0.57368 0.55831 0.55562 0.55171 0.55141 50 0.55128 0.54540 0.53514 0.53420 0.53178 0.53201 100 0.52472 0.52256 0.51588 0.51658 0.51444 0.51562 Table 6. The expected values for different estimators for unknown scale parameter β of Gamma distribution when β = 1 Method n 𝛼 𝛼 𝛼 β=0.5 β=1 β=0.5 β=1 β=0.5 β=1 20 1.27605 1.22115 1.19739 1.16928 1.10595 1.11258 30 1.16913 1.14735 1.11661 1.11124 1.06368 1.07708 50 1.10256 1.14735 1.07027 1.11124 1.04133 1.07708 100 1.04945 1.04511 1.03176 1.03317 1.01838 1.02428 Table 7. The MSE values for different estimators for unknown scale parameter β of Gamma distribution when β = 0.5 Method n 𝛼 𝛼 𝛼 β=0.5 β=1 β=0.5 β=1 β=0.5 β=1 20 0.09335 0.06904 0.06875 0.05533 0.05957 0.05055 30 0.04509 0.03596 0.03113 0.02778 0.02835 0.02615 50 0.02224 0.01936 0.01490 0.01465 0.01408 0.01412 100 0.01023 0.00824 0.00681 0.00627 0.00662 0.00615 Table 8. The MSE values for different estimators for unknown scale parameter β of Gamma distribution when β = 1 Method n 𝛼 𝛼 𝛼 β=0.5 β=1 β=0.5 β=1 β=0.5 β=1 20 0.37339 0.27617 0.27500 0.22131 0.18993 0.17587 30 0.18037 0.14383 0.12452 0.11114 0.09764 0.09486 50 0.08896 0.14383 0.05961 0.11114 0.05129 0.09490 100 0.04091 0.03295 0.02723 0.02508 0.02535 0.02386   196    Ibn Al-Haitham Jour.for Pure&Appl.Sci. IHJPAS https://doi.org/10.30526/32.1.1914 Vol. 32 (1) 2019 References 1. Hogg, R.V.; McKean, J.W.; Craig, A.T. Introduction to Mathematical Statistics, 7th ed., Pearson Education Publication, 2014. 2. Apolloni, B.; Bassis, S. Algorithmic inference of two-parameter gamma distribution. Communications in Statistics - Simulation and Computation. 2009, 38, 9, 1950 – 1968. 3. Douglas, C.M.; George, C.R. Applied Statistics and Probability for Engineering, 3rd edition, John Wiley and Sons, Inc. 2003. 4. Sahoo, S.A. Study on Bayesian Estimation of Parameters of Some Well Known Distribution Functions; Master thesis, Department of Mathematics, National Institute of Technology Rourkela-769008, India, 2014. 5. He, H.; Zhou, N.; Zhang, R. On estimation for the Pareto distribution. Statistical Methodology. 2014, 21, 49–58. 6. Alabadee, F.A.; Al-Mayali, Y.M.; Neama, I.A. A comparison between the Bayesian and the classical estimators of weibull distribution. J. Kufa Math. Comput. 2013,1, 8, 21-28. 7. Li, J.; Ren, H. Estimation of one parameter exponential family under a precautionary loss function based on record values. International Journal of Engineering and Manufacturing. 2012. 2, 3, 75-81.