Dear R-Users,
I have a question about the dglm() function from the dglm Package (V
1.6.2). The dglm() function fits double-generalized linear models as
described in
Smyth, G. K. (1989). Generalized linear models with varying
dispersion. J. R. Statist. Soc. B, 51, 47-60. I use dglm() to estimate a
simple logit (i.e. the dependent variable is a binary indicator) with varying
dispersion. Code looks like this:
example <- data.frame(
x1 = rnorm(1000,.5,1),
x2 = rnorm(1000,0,1),
y=rbinom(1000,1,.5))
model=dglm(y~x1,~x2,data=example,family=binomial("logit"))
While the model converges, it keeps telling me the following
warning:
"In eval(expr, envir, enclos) : non-integer #successes in a binomial
glm!"
I interpret the warning as urging me that I should not apply dglm()
to binary data. I am puzzled because 1) the standard glm() function
works fine with binary data and 2) my reading of Smyth's paper
suggests that the double-generalized linear model can be applied to
binary data as well.
So I guess my question is: should I ignore this warning or is there
a statistical reason why the results might be biased in one way or
the other?
Thanks for any clarifying thoughts,
Chris
[[alternative HTML version deleted]]