From: Ben Bolker <bolker_at_ufl.edu>

Date: Thu, 20 Mar 2008 10:08:51 -0400

|> Jean-Baptiste Ferdy <Jean-Baptiste.Ferdy <at> univ-montp2.fr> writes:

*|>
*

*|> >
*

*|> > Dear R users,
*

*|> >
*

*|> > I want to explain binomial data by a serie of fixed effects. My
*

problem is

|> > that my binomial data are spatially correlated. Naively, I

thought I could

|> > found something similar to gls to analyze such data. After some

reading, I

|> > decided that lmer is probably to tool I need. The model I want to

fit would

|> > look like

*|> >
*

*|> > lmer ( cbind(n.success,n.failure) ~ (x1 + x2 + ... + xn)^2 ,
*

family=binomial,

|> > correlation=corExp(1,form=~longitude+latitude))

*|> >
*

R-help_at_r-project.org mailing list

https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Thu 20 Mar 2008 - 14:18:17 GMT

Date: Thu, 20 Mar 2008 10:08:51 -0400

**-----BEGIN PGP SIGNED MESSAGE-----
**

Hash: SHA1

Douglas Bates wrote:

| On Wed, Mar 19, 2008 at 3:02 PM, Ben Bolker <bolker_at_ufl.edu> wrote:

|> Jean-Baptiste Ferdy <Jean-Baptiste.Ferdy <at> univ-montp2.fr> writes:

problem is

|> > that my binomial data are spatially correlated. Naively, I

thought I could

|> > found something similar to gls to analyze such data. After some

reading, I

|> > decided that lmer is probably to tool I need. The model I want to

fit would

|> > look like

family=binomial,

|> > correlation=corExp(1,form=~longitude+latitude))

| This is more than a notational difference. In a linear model the | effect of b is limited to the linear predictor and, through that, the | mean. The variance-covariance specification can be separated from the | mean and, hence, can be specified separately. It is easy to fool | yourself into thinking that the same should be true for generalized | linear models, just like it is easy to fool yourself into thinking | that all the arguments for the lme function will work unchanged in | lmer.

~ Fair enough. I guess the model I was thinking of was

~ Y ~ Binomial(p,N) ~ logit(p) ~ MVN(mu,Sigma) ~ mu = (determined by model matrix and predictors) ~ Sigma = (exponential spatial correlation matrix)*sigma^2

~ This model is certainly different from the model that the original poster may have been thinking of, because in the limit where there is no extra-binomial variation, there can't be any correlation either. On the other hand, it seems to be a sensible model.

~ cheers

~ Ben Bolker

**-----BEGIN PGP SIGNATURE-----
**

Version: GnuPG v1.4.6 (GNU/Linux)

Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFH4m/zc5UpGjwzenMRAi02AJ9UNy8WsUkN8hVI5ih1yOLxtQn3TwCfeovt
Q1iOmczhkWqi4d4VeZDcylo=

=Mr7v

**-----END PGP SIGNATURE-----
**

R-help_at_r-project.org mailing list

https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Thu 20 Mar 2008 - 14:18:17 GMT

Archive maintained by Robert King, hosted by
the discipline of
statistics at the
University of Newcastle,
Australia.

Archive generated by hypermail 2.2.0, at Thu 20 Mar 2008 - 14:30:24 GMT.

*
Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help.
Please read the posting
guide before posting to the list.
*