ggammaUC                package:VGAM                R Documentation

_T_h_e _G_e_n_e_r_a_l_i_z_e_d _G_a_m_m_a _D_i_s_t_r_i_b_u_t_i_o_n

_D_e_s_c_r_i_p_t_i_o_n:

     Density, distribution function, quantile function and random
     generation for the generalized  gamma distribution with scale
     parameter 'scale', and parameters 'd' and 'k'.

_U_s_a_g_e:

     dggamma(x, scale=1, d=1, k=1)
     pggamma(q, scale=1, d=1, k=1)
     qggamma(p, scale=1, d=1, k=1)
     rggamma(n, scale=1, d=1, k=1)

_A_r_g_u_m_e_n_t_s:

    x, q: vector of quantiles.

       p: vector of probabilities.

       n: number of observations. Positive integer of length 1.

   scale: the (positive) scale parameter b.

    d, k: the (positive) parameters d and k.

_D_e_t_a_i_l_s:

     See 'ggamma', the 'VGAM' family function for estimating the
     generalized gamma distribution by maximum likelihood estimation,
     for formulae and other details. Apart from 'n', all the above
     arguments may be vectors and are recyled to the appropriate length
     if necessary.

_V_a_l_u_e:

     'dggamma' gives the density, 'pggamma' gives the distribution
     function, 'qggamma' gives the quantile function, and 'rggamma'
     generates random deviates.

_A_u_t_h_o_r(_s):

     T. W. Yee

_R_e_f_e_r_e_n_c_e_s:

     Stacy, E. W. and Mihram, G. A. (1965) Parameter estimation for a
     generalized gamma distribution. _Technometrics_, *7*, 349-358.

_S_e_e _A_l_s_o:

     'ggamma'.

_E_x_a_m_p_l_e_s:

     ## Not run: 
     x=seq(0, 14, by=0.01); d=1.5; Scale=2; k=6
     plot(x, dggamma(x, Scale, d, k), type="l", col="blue", ylim=c(0,1),
          main="Blue is density, red is cumulative distribution function",
          sub="Purple are 5,10,...,95 percentiles", las=1, ylab="")
     abline(h=0, col="blue", lty=2)
     lines(qggamma(seq(0.05,0.95,by=0.05), Scale, d, k), 
           dggamma(qggamma(seq(0.05,0.95,by=0.05), Scale, d, k), Scale, d, k),
           col="purple", lty=3, type="h")
     lines(x, pggamma(x, Scale, d, k), type="l", col="red")
     abline(h=0, lty=2)
     ## End(Not run)

