Re: [R] nlme, MASS and geoRglm for spatial autocorrelation?

From: Ruben Roa <RRoa_at_fisheries.gov.fk>
Date: Wed 13 Jul 2005 - 23:03:53 EST


> -----Original Message-----
> From: r-help-bounces@stat.math.ethz.ch
> [mailto:r-help-bounces@stat.math.ethz.ch]On Behalf Of Beale, Colin
> Sent: 13 July 2005 10:15
> To: Prof Brian Ripley
> Cc: r-help@stat.math.ethz.ch
> Subject: Re: [R] nlme, MASS and geoRglm for spatial autocorrelation?
>
>
> My data are indeed bernoulli and not binomial, as I indicated. The
> dataset consists of points (grid refs) that are either locations of
> events (animals) or random points (with no animal present). For each
> point I have a suite of environmental covariates describing
> the habitat at this point. I was anticipating some sort of function that
> could run:
>
> function(present ~ env1 + env2 + env3 + x + y, correlation =
> corSpher(form=~x+y), family = binomial)
>
> where env1 to env3 are the habitat covariates, x & y the grid refs. If
> my data were normal, I undertand I would use gls() with exactly this,
> but drop the family requirement. As my data are bernoulli this is
> clearly not possible, but I was hoping the analysis may be analagous?
> The eventual aim is to firstly understand which environmental
> covariates are important in determining presence and then to use habitat maps to
> identify the areas expected to be most important.

This could be done with geoRglm. I did something similar last week, but without covariates, only the spatial coordinates (i.e. my spatial process had expectation equal to a constant). If you are willing to sacrifice some spatial resolution you can create cells in your spatial data (say 100 m x 100 m) and in each cell count the number of successes in observing your spatial process and the number of trials. This will be a binomial problem and it seems to me to be the spatial equivalent of logistic regression where the predictor continuous variable is structured in bins and then events are counted in those bins. You can move to the R-sig-geo list if you have questions about geoRglm
https://stat.ethz.ch/mailman/listinfo/r-sig-geo Btw, this can also be done in SAS using the glimmix macro. Ruben



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Thu Jul 14 01:07:33 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:33:37 EST