[R] nlme: correlation structure in gls and zero distance

From: Patrick Giraudoux <patrick.giraudoux_at_univ-fcomte.fr>
Date: Sun 02 Jul 2006 - 02:57:10 EST


Dear listers,

I am trying to model the distribution of fox density over years in the Doubs department. Measurements have been taken on 470 plots in March each year and georeferenced. Average density is supposed to be different each year.

In a first approach, I would like to use a general model of this type, taking spatial correlation into account:

gls(IKAfox~an,correlation=corExp(2071,form=~x+y,nugget=1.22),data=renliev)

but I get

>

gls(IKAfox~an,correlation=corExp(2071,form=~x+y,nugget=1.22),data=renliev) Error in getCovariate.corSpatial(object, data = data) :

        Cannot have zero distances in "corSpatial"

I understand that the 470 geographical coordinates are repeated three times (measurement are taken each of the three years at the same place) which obviously cannot be handled there.

Does anybody know a way to work around that except jittering slightly the geographical coordinates?

Thanks in advance,

Patrick



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 Sun Jul 02 03:02:03 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Sun 02 Jul 2006 - 06:13:36 EST.

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