Formulas{bivpois}

R Documentation

Details on Formula Arguments

for functions lm.bp and lm.dibp

               In the formula1 argument of functions lm.bp and lm.dibp the response should always be defined as y1y2.  The syntax of  formula1 is similar as all formula objects in R. The operators <+, :, *>  are used as in normal formula objects to define additional main effects, interaction terms, or both. Three additional arguments/variables are defined internally in lm.bp and lm.dibp in order to help us build the model: noncommon, l1 and l2.

Ø      Variable noncommon  is used to specify which terms will be different for the linear predictors of  ë1 and ë2.

Ø      Variable l1  is used to specify which terms will have effect only on ë1 using a syntax of type ‘+I(X*l1)' or ‘+I(l1*X)'.

Ø      Variable l2  is used to specify which terms will have effect only on ë2 using a syntax of type ‘+I(X*l2)' or ‘+I(l2*X)'.

Hence the following combinations can be used

1.  `+X:noncommon' or `+X*noncommon': The variable X has different effect on ë1  and ë2.

2.  `+X': When additional terms of the form `+X:noncommon' or  `+X*noncommon' are not included in formula then the variable X has common effect on both ë1 and ë2.

3. `+I(X*l1)' or `+I(l1*X)': The effect of variable X  is estimated only for the linear predictor of ë1 (while for the linear predictor of  ë2 is set equal to zero).

4. `+I(X*l2)' or `+I(l2*X)': The effect of variable X  is estimated only for the linear predictor of  ë2  (while for the linear predictor of  ë1 is set equal to zero).

For the argument formula2 the response should always be defined as y3 while its syntax is the same as all formula objects in R.

Some usual models are the followin

1.      y1y2~1                      : Common constant for ë1 and ë2 that is log(ë1i )= â0  and log(ë2i )= â0 .

2.      y1y2~noncommon      : Constant but not equal ë1 and ë2  that is log(ë1i )= â1,0  and log(ë2i )= â2,0  with â1,0¹â2,0.

3.      y1y2~.                  : Full model with different parameters for ë1 and ë2.

Finally, in both lm.bp and lm.dibp we can construct models for which different variables have the same effect on ë1 and ë2. This can be achieved using terms of type c(z1,z2). Such as a term results to a common parameter for both ë1 and ë2 for the variable z1 and z2 respectively.

Ôhe formula

        y1y2 $\sim$ noncommon + c(z1,z2)+z4:noncommon + z5

 will result to the following model

               log(ë1)  =  â1,0 + â12 z1 + â1,4 z4  + â5 z5

               log(ë2) =  â2,0 + â12 z2 + â2,4 z4  + â5 z5

References

1.      Karlis, D. and Ntzoufras, I. (2004). Bivariate Poisson and Diagonal Inflated Bivariate Poisson Regression Models in S. (submitted). Technical Report, Athens University of Economics and Business, Athens, Greece.

2.      Karlis, D. and Ntzoufras, I. (2003). Analysis of Sports Data Using Bivariate Poisson Models. Journal of the Royal Statistical Society, D, (Statistician), 52, 381 – 393.

Authors Information

1.      Dimitris Karlis, Department of Statistics, Athens University of Economics and Business, Athens, Greece, e-mail: karlis@aueb.gr .

2.      Ioannis Ntzoufras, Department of Statistics, Athens University of Economics and Business, Athens, Greece, e-mail: ntzoufras@aueb.gr  .

See Also

lm.bp, lm.dibp .

Examples

Ôhe formula

        y1y2 $\sim$ noncommon + c(z1,z2)+z4:noncommon + z5

 will result to the following model

               log(ë1)  =  â1,0 + â12 z1 + â1,4 z4  + â5 z5

               log(ë2) =  â2,0 + â12 z2 + â2,4 z4  + â5 z5

see also examples 1 – 4: ex1.sim, ex2.sim, ex3.health, ex4.ita91 .


[Package Contents]