Dear list,

I am new to this list and I am trying to fit a Spatial Eigenvector GLM to
count data.

I am trying to fit a ME model in spdep package to investigate environmental
drivers on Bryde's whale distribution. I have 3 environmental variables
(depth, distance to coast, slope), my response variable is the occurrence
(counts) of whales in 82 km2 grids.

I used the dnearneigh function to build .nb data using the coordinates data.
>    nb1  <-  dnearneigh(xy,  0,  10)  ----
and: lw1  <-  nb2listw(nb1,  style="W")

x - is latitude coordinates
y - is longitude coordinates


Using the glm and Spatial filtering function (as done in spdep manual) I
had no problems. However, when I used the 'ME' it says: base correlation
larger than alpha. My alpha is 0.05.

Here it is my code:
##This part works well
glmbase1  <-  glm(OCC  ~  DEPTH  +  DISTCOAST+SLOPE,  offset=RT,
data=bryde3)

lagcol1  <-  SpatialFiltering(OCC_BIN  ~  1,  ~  DEPTH  +  DISTCOAST+
SLOPE, data=bryde3,  style="W",  nb=nb1, alpha=0.05,  verbose=TRUE)

glmlag1  <-  glm(OCC ~  DEPTH  +  DISTCOAST+SLOPE +  fitted(lagcol1),
 offset=RT,data=bryde3)

anova(glmlag1)
anova(glmbase1,  glmlag1)
set.seed(123)

##From here on, it does not
lagcol1  <-  ME(OCC ~  DEPTH  +  DISTCOAST+SLOPE,  offset=RT, data=bryde3,
 family="poisson",
listw=lw1,  alpha=0.05,  verbose=TRUE)

Error in ME(OCC ~ DEPTH + DISTCOAST + SLOPE, data = bryde3, family =
"poisson",  :
  base correlation larger than alpha

When I increase alpha to 0.6 (lower values keep saying the same error),
this error message does not appear. However, when I try to rerun GLM with
eigenvectors included as covariates (as done in spdep manual - page 118) I
have the following error message:

Error in glm.fit(x = c(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,  :
  NA/NaN/Inf in 'x'
warning message: step size truncated due to divergence

Can anyone please help me?
Other question, if I may, is there a strong difference between Spatial
Filtering and ME?

Many thanks in advance,
Rodrigo
-- 
Rodrigo Tardin

Doutorando em Ecologia e Conservação - IBRAG - UERJ
Mestre em Biologia Animal - PPGBA - UFRRJ
Especialista em Docência do Ensino Superior - IAVM
Laboratório de Bioacústica e Ecologia de Cetáceos - UFRRJ/ IF/ DCA

	[[alternative HTML version deleted]]

