[R-sig-eco] Using ME() of spdep: too many observations? how to make it step by step?
vega_l at yahoo.com
vega_l at yahoo.com
Mon Jun 15 06:14:13 CEST 2009
Good afternoon and greetings to everyone!
We are trying to remove the spatial structure of our data by employing Moran Eigen Vectors with the spdep package. Our dataset is kind of large, 3694 samples and 13 variables.
The bad news: my Dual Core 2.0 MHz laptop with Ubuntu 9.04 (2.0 Gb RAM) halted after almost 4 days of continuous processing, and all the effort was lost. (Why the calculations took so much time??)
I wonder if there is a way to accelerate the calculations with ME() and to save the resulting eigenvalues as they get calculated. Or if it is possible to make the calculation process of ME() step by step.
The code in R is a follows:
taimin.xy = taimin[c("dy", "dx")];
coordinates(taimin.xy) <- ~dy+dx; #dy, dx, name of the respective
coordinate columns
coords<-coordinates(taimin.xy);
library(spdep);
TaiminGabrielGraph<-gabrielneigh(coords, nnmult = 12);
tai.gab.nb<-graph2nb(TaiminGabrielGraph,sym=TRUE);
nbtaim_distsg <- nbdists(tai.gab.nb, coords);
nbtaim_simsg <- lapply(nbtaim_distsg, function(x) (1-((x/(4*50))^2)) );
MEtaig.listw <- nb2listw(tai.gab.nb, glist=nbtaim_simsg, style="B");
sevmtaig <- ME(Presabs
~Age+Curv+Zon2005+ZoneMeiji+Wi+Sol+Slope+Seadist+Elev+Basin,data=taimin,
family=binomial,listw=MEtaig.listw)
I hope someone can give me some help.
Thank you!
____________________________________________________________________________________
¡Obtén la mejor experiencia en la web!
Descarga gratis el nuevo Internet Explorer 8.
http://downloads.yahoo.com/ieak8/?l=e1
More information about the R-sig-ecology
mailing list