posbinomial               package:VGAM               R Documentation

_P_o_s_i_t_i_v_e _B_i_n_o_m_i_a_l _D_i_s_t_r_i_b_u_t_i_o_n _F_a_m_i_l_y _F_u_n_c_t_i_o_n

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

     Fits a positive binomial distribution.

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

     posbinomial(link = "logit", earg=list())

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

    link: Link function for the usual probability parameter.    See
          'Links' for more choices.

    earg: List. Extra argument for the link. See 'earg' in 'Links' for
          general information.

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

     The positive binomial distribution is the ordinary binomial
     distribution but with the probability of zero being zero. Thus the
     other probabilities are scaled up (i.e., divided by 1-P(Y=0)).

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

     An object of class '"vglmff"' (see 'vglmff-class'). The object is
     used by modelling functions such as 'vglm', 'rrvglm' and 'vgam'.

_W_a_r_n_i_n_g:

     Under- or over-flow may occur if the data is ill-conditioned.

_N_o_t_e:

     The input for this family function is the same as 'binomialff'.

     Yet to be done: a 'quasi.posbinomial' which estimates a dispersion
     parameter.

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

     Thomas W. Yee

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

     Patil, G. P. (1962) Maximum likelihood estimation for generalised
     power series distributions and its application to a truncated
     binomial distribution. _Biometrika_, *49*, 227-237.

     Documentation accompanying the 'VGAM' package at <URL:
     http://www.stat.auckland.ac.nz/~yee> contains further information
     and examples.

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

     'binomialff'.

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

     # Number of albinotic children in families with 5 children
     # Data from Patil (1962) 
     y = c(rep(1,25), rep(2,23), rep(3,10), 4, 5)  # No zeros 
     n = rep(5, 60)
     yprop = y / 5
     # Fit the identical models in two ways; MLE of p is 0.3088 
     fit = vglm(yprop ~ 1, posbinomial, trace=TRUE, weights=n)
     fit2 = vglm(cbind(y, n-y) ~ 1, posbinomial, trace=TRUE)
     summary(fit)
     summary(fit2)
     Coef(fit2)   # = MLE of p
     Coef(fit)    # = MLE of p
     fitted(fit2)[1:2]
     fitted(fit)[1:2]

