Loading...

ADVANCES IN COMPUTER SCIENCES (ISSN:2517-5718)

On Modeling the Double and Multiplicative Binomial Models as Log-Linear Models

Bayo H Lawal*

Department of Statistics & Mathematical Sciences, Kwara State University, Malete, Kwara State, Nigeria

CitationCitation COPIED

Lawal BH. On Modeling the Double and Multiplicative Binomial Models as Log-Linear Models. Adv Comput Sci.2018 Jan; 1(1):103.

Abstract

In this paper we have fitted the double binomial and multiplicative binomial distributions as log-linear models using sufficient statistics. This approach is not new as several authors have employed this approach, most especially in the analysis of the Human sex ratio in [1]. However, obtaining the estimated parameters of the distributions may be problematic, especially for the double binomial where the parameter estimate of π may not be readily available from the Log-Linear (LL) parameter estimates. Other issues associated with the LL approach is its implementation in the generalized linear model with covariates. The LL uses far more parameters than the procedure that employs conditional log-likelihoods functions where the marginal likelihood functions are minimized over the parameter space. This is the procedure employed in SAS PROC NLMIXED. The two procedures are essentially equivalent for frequency data. For models with covariates, the LL uses far more parameters and the marginal likelihood functions approach are employed here on three data set having covariates.

Keywords

Double Binomial; Multiplicative Binomial; Log-Linear; Marginal Likelihood Functions

Introduction

In the formulations of the multiplicative binomial distribution, in Altham and its corresponding double binomial distribution in Efron, both distributions were characterized with intractable normalizing constants c(n, ψ) and c(n, π) respectively [2,3]. Consequently, these models were implemented in by utilizing a generalized linear model with a Poisson distribution and log link to the frequency data. This approach has earlier being similarly employed in [1,4]. This approach which employs joint sufficient statistics in both distributions was earlier proposed in Lindley & Mersch [5].

Both distributions are fitted using a Poisson regression model having sufficient statistics from both distributions as explanatory variables with the frequencies being the mean dependent variables. For the Double binomial model (DBM), the sufficient statistics are y log(y) and (n − y) log(n − y). Similar joint sufficient statistics for the multiplicative binomial model (MBM) are y and y(n − y) with the offset being


However, in recent times, both models have been fully formulated with the intractable normalizing constants fully formulated. These distributions are described later in this paper with the normalizing constants fully formulated. In this study, we compare fitting these two probability models to two example frequency data, two data set examples arising from teratology studies, and randomized complete block design example having binary outcome by the method of sufficient statistics described above and by the method of numerically maximizing the marginal likelihood function arising from engaging the problem as a mixed generalized linear model. The SAS PROC NLMIXED which performs the Maximum Likelihood estimation numerically by using the Adaptive Gaussian Quadrature and Newton-Raphson optimization algorithm. We shall designated the sufficient StatisticsPoisson regression approach as LL, while the marginal likelihood function maximization via PROCNLMIXED is designated MgL in this study. The sufficient statistics procedure uses a Poisson regression with an offset and is implemented in SAS PROC GENMOD.

Models Under Consideration

We describe in the following section, the two probability distribution models employed in this paper.

The Multiplicative Binomial Model-MBM

[2,6,7] Lovinson proposed an alternative form of the twoparameter exponential family generalization of the binomial distribution first introduced by [2] which itself was based on the original Cox representation as:



the denominator expression in (3) in this case. [8] presented an elegant characteristics of the multiplicative binomial distribution including its four central moments. His treatment includes generation of random data from the distribution as well as the likelihood profiles and several examples-some of which are similarly employed in this presentation. Following [8] the probability \[\pi\] of success for the Bernoulli trial, that is, P(Y = 1) can be computed from the following expression in (4) as:


with p defined as in (4),  Ψ therefore can be defined as the probability of success weighted by the intra-units association measure  ω which measures the dependence among the binary responses of the n units. Thus if ω = 1, then p =  Ψ and we have independence among the units. However, if ω  = 1, then, p =  Ψ and the units are not independent.

The mean and variance of the LMPD are given respectively as:


The Double Binomial (DBM) Model

In Feirer et al. [7], the double binomial distribution was presented, having the pdf form:


Applications

We apply the models discussed above to two frequency data and to teratology data sets having four and two treatment groups. We first present the analyses for the two frequency data sets in Tables 1 through 5. The estimation of the parameters under each model for the MgL approach uses SAS PROC NLMIXED, using the following log-likelihoods for the MBM (LL1) and DBM (LL2) respectively. The procedure was discussed earlier in the paper.



Example Data Set I-Geissler Data

The Distribution of males in 6115 families with 12 children in Saxony, previously analyzed in Sokal & Rohlf [10] is presented in Table 1. The data is originally from Geissler [11] and had similarly been analyzed in [12]. Here Y ~ binomial (12,π] ). The frequencies are presented as counts having a total sum of 6115. The observed mean for the data is Y_= 6.2306 and the corresponding variance is S2 = 3.4898. Under the binomial model, the estimated mean is 6.2304 and estimated variance being 2.9956. Hence the estimated dispersion parameter DP= Y_ /S2= 2.07 indicating over-dispersion in the data. The estimated probability of occurrence under the binomial model is π = 0.5192. The binomial does not fit the data(X2  = 110.5051 on 11 d.f., p-value=0.0000) because the variance of the data is grossly under estimated by the model. The results of the application of the double binomial and the multiplicative models to this data are presented in Table 2. Further, the mixed model approach is based on one more degree of freedom as it estimates one parameter less than the LL model approach. The Mixed model approach gives the parameter estimates of the distribution. We can obtain the equivalent parameters estimates from the Log-linear (LL) approach for the multiplicative models as follows:


For the DB,  can equivalently be obtained as 1 − = 1 − 0.140205 = 0.8598, but the estimated probability  π_ seems intractable in this case and no equivalent solution is available in this case. We may note here that the estimate ψ _ = 0.5165 under the multiplicative model is not an estimate of the success probabilityπ . For this data, we must use the expressions in (4) and (5) to obtain this estimate. Here,


The mean and Variance can therefore be computed respectively from (6a) and (6b). Alternatively, the means and variances can be empirically obtained from the fitted models using the elementary principles of 

In the above Table, Some of the columns are self explanatory. The columns labeled V1 and V2 are cumulative values of 

for both models respectively. Thus, the mean is the value at y = 12. The variance for the DBM for instance, is computed as 42.3116− (6.2306)2 = 3.4915.


In Table 4 are presented the expected values under both models for the two approaches (LL & MgL), both approaches give exact results as expected. The Table also displays the mean of the distributions under both approaches as well as the empirical variances, designated here as var. We recall that for the observed data in Table 1, y = 6.2306 and s2 = 3.4898.We see from Table 4, that while the two models estimate the mean of the data well, the estimated variance under the binomial model of 12(0.5192)(1−0.5192) = 2.9956 underestimates the observed variance of the data, and this explains the poor fit to the data by the binomial model. On the other hand, for the two models, the variance of the observed data are reasonably well estimated, because of the extra parameter in the model (dispersion parameter) of φ and ω for the DBM and MBM respectively.

Table 4 also displays the corresponding Pearson‘s X2 and the corresponding degrees of freedom (d.f.). Clearly, for this data set, both the double binomial and the multiplicative models fit the data well with the Double binomial being slightly providing a better fit. Although the expected values generated are the same for both fitting approaches, we see that the marginal likelihood (MgL) approach gives a more parsimonious model because it is based on one more degree of freedom.

Table 1: Distribution of Males in 6115 families with 12 children


Table 2: Parameter estimates under the five Models


Table 3: Empirical Means and Variances for both the DBM and MBM



Table 4: Expected values under the two models and Approaches with corresponding Pearson’s \[X^{2}\] Statistic values



Table 5: Expected Values under the two models and approaches with corresponding Pearson’s \[X^{2}\] Statistic Values 

Regression Model Formulations

When there are covariates in our data, the sufficient statistic approach-here into referred to as Log-linear (LL) does not lend itself to easier formulation and implementation. Lindsey and Altham [13] employed this approach to fitting amongst others, the two models considered in this study to the distribution of males in families in Saxony during 1885-1976 (the human sex ratio data). This approach employs far too many parameters, 13 to be precise when the same group of models can be implemented with only four parameters with the same results. Further, the implementations under this approach are not readily available. Thus in this study, we will employ the alternative MgL procedure that utilizes PROC NLMIXED in SAS. One advantage of this is that it will based on more degrees of freedom than the log-linear model. We see for the frequency data in Tables 1 for instance, that the LL approach is based on 1 d.f. more than the MgL model based.

Example I: Teratology-Ossification on the Phalanges

Teratology is the study of abnormalities of physiological development. The offspring of animals that were exposed to a toxin during pregnancy are studied for malformation. The number of malformed offspring in a litter of size n is not typically distributed binomial because the responses of the offspring from the same litter are not independent, hence their sum does not constitute a binomial r.v. Thus, data in teratological studies exhibit over-dispersion because of the correlation among responses from off springs in the same litter.

[14] report data from a completely randomized design that studies the teratogenicity of phenytoin in 81 pregnant mice. The treatment structure of the experiment is an augmented factorial. In addition to an untreated control, mice received 60 mg/kg of phenytoin (PHT), 100 mg/kg of trichloropropene oxide (TCPO), and their combination. The design was augmented with a control group that was treated with water. As in [15], the two control groups are combined here into a single group. The presence or absence of ossification in the phalanges on both the right and left forepaws on each of the fetuses is considered a measure of the teratogenic effect. The data is presented below. For the control for instance, there are 35 pair of observations designated as (n , r). Thus, the numbers of rats in each group are respectively {35,19,16,11}. 

control 35 8 8 9 9 7 9 0 5 3 3 5 8 9 10 5 8 5 8 1 6 0 5

8 8 9 10 5 5 4 7 9 10 6 6 3 5 8 9 7 10 10 10

1 6 6 6 1 9 8 9 6 7 5 5 7 9 2 5 5 6 2 8 1 8

0 2 7 8 5 7

PHT  19 1 9 4 9 3 7 4 7 0 7 0 4 1 8 1 7 2 7 2 8 1 7

0 2 3 10 3 7 2 7 0 8 0 8 1 10 1 1

TCPO  16 0 5 7 10 4 4 8 11 6 10 6 9 3 4 2 8 0 6 0 9

3 6 2 9 7 9 1 10 8 8 6 9

PHT2   11 2 2 0 7 1 8 7 8 0 10 0 4 0 6 0 7 6 6 1 6 1 7

Suppose Yij denote the number of deaths in litter i. Further, let pij be the probability of a fetus in litter i dying. Yij has the overdispersed binomial distribution with mean ni pij and variance ni pij(1 − pij )φ , with φ characterizing the correlation between any two fetuses within the same litter.

The probability of fetal death is modeled with the logit link viz:


We have assumed here that β0 is similar across litters, and that,

Thus, the ‘control’ treatment is the reference category in this set up. Our analysis begins by fitting three different models to the data. These models are described briefly below:
  • The model that assumes \[p_{0}=p_{1}=p_{2}=p_{3}\] with a common dispersion parameter \[\phi\] or \[\omega\] for the double binomial and the multiplicative models respectively, and, where \[p_{0}\] and \[p_{1}\], \[p_{3}\], \[p_{3}\] refer respectively to the corresponding probabilities in the control and other treatment groups.

  • The model here has pi = pj i i ≠ j and the dispersion parameters are functions of the covariates. That is, φ = exp (a0 + a2 z2 + a3 z3 + a4 z4 ) and ω = exp(c0 +c2 z2 + c3 z3 + c4 z4 ). 
  • The model here has pi ≠ pj with the ps modeled as in (9) and the dispersion parameters are modeled as functions of the covariates as in the preceding case.

Results

From the results in Table 6, the two cases (II & III) with variable dispersion parameters fit better than the model in case I, where the dispersion is uniform across the four groups. Of the models in Cases II and III, the models in case III fits much better than those in case II. Case II models assume that the four groups have a common estimated probability \[\pi\], which are estimated respectively as 0.2125 and 0.2158 in both the DBM and MBM. However, the models in III which assume heterogeneous success probabilities across the four groups and variable dispersion parameters (that are functions of the covariates) fit better than those in case II. The DBM here is based on \[X^{2}\] = 115.1333 on 72 d.f. The estimated \[\pi\] s under the MBM are functions of n, hence these values are different for different n in the final model (Case III). We may note here that the Ψs should not be mistaken for the success probabilities.


Table 6: Parameter estimates for the Models in all the Cases



Table 7: Number of Surviving eggs against number of eggs in a box


Table 8: Results of Analysis of Data in Table 



Table 9: Parameter estimates under the multiplicative model with variable dispersion parameter


Table 10: Parameter estimates under the three cases for the two probability models.

Appendix A. SAS Program for the Example

options nodate nonumber ls=85 ps=66;

data ex1;

do L=1 to 5;

do T=1 to 4;input y n @@;

output;

end; end;

datalines;

89 94 94 98 77 86 141 155

106 108 91 106 87 96 104 122

119 123 100 130 88 119 91 125

104 104 80 97 67 99 111 132

49 93 11 113 18 88 0 138 ;

run;

proc print;

run;

/*generate indicator variables for Location*/; data w1;

set ex1;

array x(5) z1-z5;

do j=1 to 5;

if j=L then x(j)=1;

else x(j)=0;

end;

drop j;

run;

/*generate indicator variables for Time*/;

data w2;

set ex1;

array d(4) x1-x4;

do k=1 to 4;

if k=T then d(k)=1;

else d(k)=0;

end;

drop k;

run;

data new;

merge w1 w2;

run;

proc sort data=new;

by T;

run;

proc nlmixed data=new tech=newrap maxit=2000;

parms b0=-0.1 b1=1.1 b2=0.4 b3=.1 b4=0.2 s1-s3=0.0 a0=0 a1=0 a2=0 a3=0;

lp=b0+b1*z1+b2*z2+b3*z3+b4*z4+s1*x1+s2*x2+s3*x3;

lr=a0+a1*x1+a2*x2+a3*x3; omega=exp(lr);

p=1/(1+exp(-lp)); sum=0.0;

do j=0 to n;

z1=lgamma(n+1)-lgamma(j+1)-lgamma(n-j+1);

u=z1+ j*log(p) + (n-j)*log(1-p) + j*(n-j)*log(omega);

sum=sum+exp(u);

end;

keep sum;

z2=lgamma(n+1)-lgamma(y+1)-lgamma(n-y+1);

LL=z2+ y*log(p) + (n-y)*log(1-p) + y*(n-y)*log(omega)-log(sum);

model y~general(LL);

predict p out=aa;

predict omega out=bb;

run; Ods rtf close;

data q1;

set aa;

psi=pred;

run;

data q2;

set bb;

omega=pred;

run;

data qq4;

merge q1 q2;

suma=0;

do j=0 to n;

zz1=lgamma(n+1)-lgamma(j+1)-lgamma(n-j+1);

u1=zz1+ j*log(psi) + (n-j)*log(1-psi) + j*(n-j)*log(omega);

suma=suma+exp(u1);

end;

sumb=0;

do k=0 to n-1;

zz2=lgamma(n)-lgamma(k+1)-lgamma(n-k);

u2=zz2+ k*log(psi) + (n-k-1)*log(1-psi) + (k+1)*(n-k1)*log(omega);

sumb=sumb+exp(u2);

end;

sumc=0;

do t=0 to n-2;

zz3=lgamma(n-1)-lgamma(t+1)-lgamma(n-1-t);

u3=zz3+t*log(psi)+(n-t-2)*log(1-psi)+(t+2)*(n-t-2)*log(omega);

sumc=sumc+exp(u3);

end;

/* Generate p1,p2, expected values and variances*/;

p1=psi*(sumb/suma);

p2=(psi*psi)*(sumc/suma);

exp=n*p1;

var=n*p1+(n*(n-1)*p2)-(n*n*p1*p1);

/* Generate Wald, LRT and Pearson’s GOFs */;

wald+((y-exp)**2)/var;

if y=0 then lrt+0;

else lrt+2*y*log(y/exp);

XX+((y-exp)**2)/exp;

run;

proc print data=qq4;

var n y psi p1 p2 exp omega var XX LRT Wald;

format psi p1 p2 exp omega var xx LRT Wald 10.4;

run;


Table 11: Parameter estimates under the multiplicative model with constant dispersion parameter.


Results

Results from Table 10 show that for cases I to III, the model for case II is the most parsimonious. The difference between the Likelihood-test statistic, \[G^{2}\] between models II and III being 0.2307 on 1 d.f (p-value=0.6310), which is not significant. We have used the \[G^{2}\] rather than the Wald or Pearson’s \[X^{2}\] because only the \[G^{2}\] statistic has the partitioning property, (see, [18]). However, while this model seems the best, it does not tell us much about the probability of success (\[\pi_{i}\] , i = 0, 1) for each group. The model assumes a common success probability for both groups. Our results further indicate that we probably do not need variable dispersion parameters for both probability models, that is, a common dispersion parameter would be adequate since neither the \[\phi\]or \[\omega\] associated with the treatment groups are significant in model III. Thus, a reduced model of case III which models the probability of success separately for the treatments but assumes a common dispersion parameter. The models are based on 16 d.f. Here, under the double binomial model, the estimated probabilities of fetal deaths for the control and experimental groups are respectively 0.0552 and 0.2332 and these estimated probabilities are constant across the treatment levels. The corresponding goodness-of-fit values are \[G^{2}\] = 9.1437 and \[X^{2}\]= 22.9671 with common dispersion parameter estimate being \[\hat{\phi}\] = 0.4900. We notice a considerable discrepancy between the values of \[G^{2}\] and \[X^{2}\] for this data here. This is because, of the twenty observations in the data, nine of them have zeros for the values of Y. Consequently, these observations do not contribute to the overall \[G^{2}\] and this accounts for the lower values of \[G^{2}\] compared to their corresponding \[X^{2}\] .

For the MBM, while the estimated \[\psi\] are specific to each treatment and constant across each treatment, the estimated probabilities \[\pi_{1}\] of successes vary by the number of litters n as outlined in expression (4). Thus for n = 8, \[\pi_{1}\]  equals 0.0769 and 0.2469 respectively for the control and treatment groups. We present in Table 11 the estimated probabilities and other variables under the multiplicative model for this case.

Conclusion

Results presented in the preceding sections showed that while it is relatively easier to fit both the double binomial and the multiplicative binomial with joint sufficient statistics employing Poisson regression for frequency data, this approach cannot easily be implemented with data having co-variates. Further, the sufficient statistics approach is based on more degrees of freedom than the MgL method, which makes the MgL method more parsimonious in all cases. We would encourage the use of the MgL methods in applications of these models to binary count data. Of the two binomial models, the multiplicative binomial seems more consistent and fits much better than the double binomial. Further, it does not have much convergence problems than the DBM.

The SAS programs for implementing all the models discussed in this paper are readily available from the author. Meanwhile, we have attached a typical program in the appendix for implementing the MGM for the Manly data discussed in section 5.3.

References

  1. Lindsey JK, Altham PK. Analysis of the human sex ratio by usingover dispersion models. Appl Statist. 1998; 47: 149-157. 
  2. PM Altham. Two generalizations of the binomial distribution.Appl Statist. 1978; 27: 162-167. 
  3. B Efron. Double exponential families and their use in generalizedlinear regression. J Amer Statist Assoc. 1986; 81: 709-721. 
  4. Lindsey JK. Modelling Frequency and Count Data. OxfordUniversity Press; 1995. 
  5. Lindsey JK, Mersch G. Fitting and comparing probabilitydistributions with log linear models. Comput Stat Data Anal.1992; 13: 373-384. 
  6. Lovinson G. An alternative representation of Altham’smultiplicative-binomial distribution. Stat Proba lett. 1998; 36:415-420. 
  7. DR Cox. The analysis of multivariate binary data. Appli Stat. 1972;21: 113-120. 
  8. EAH Elamir. Multiplicative-binomial distribution: Some resultsand characterization, inference and random data generation. JStat Theory Appl. 2013; 12: 92-105. 
  9. Feirer V, Friedl H, Hirn U. Modeling over-and under dispersedfrequencies of successful ink transmissions onto paper. J ApplStat. 2013; 40: 626-643. 
  10. Sokal RR, Rohlf FJ. Biometry: the Principles and Practice ofStatistics in Biological Research. San Francisco: Freeman; 1969. 
  11. Geissler A. Contribution to the question of the sexual relationship of the born. Sachs Super numerary Bur. 1889; 35: 1-24.
  12. Borges P, Rodrigues J, Balakrishnan N. A Com-Poisson typegeneralization of the Binomial distribution and its properties andapplications. J Stat Prob Letters. 2014; 87: 158-166.
  13. Nelder JA, Mead R. A simplex method for function minimization.Comput J. 1965; 7: 308-312. 
  14. Morel JG, Neerchal NK. Clustered binary logistic regression interatology data using a finite mixture distribution. Stat Med.1997; 16: 2843-2853. 
  15. Morel JG, Neerchal NK. Overdispersion Models in SAS. SASpublication. 2012.
  16. Manly B. Regression models for proportions with extraneous variance, Biometrie-Praximetrie. 1978; 18: 1-18.
  17. Lawal HB. Categorical Data Analysis with SAS and SPSSApplications. Taylor & Francis. 2003; New York, USA.