[R-sig-Geo] using gwr

Virginia virginia at dpi.inpe.br
Tue Nov 11 14:06:29 CET 2008


I have some questions:

I got an error. I dont't know why.

Somebody to help me?

Thanks,

   Virginia Ragoni

require(spgwr)
require(foreign)
x <- read.shape("cidade.shp")
plot(x)
mappolys <- Map2poly1(x,as.character(x$att.data$ID9100),raw=FALSE)

mapbbs=Map2bbs(x)
mapcents=get.Pcent(x)
tab= x$att.data

# cálculo da largura da banda
sjc.bw <- gwr.sel((tab$TX_CRESC~tab$LOGDEN),data=tab,coords=mapcents)

# error -  Erro em spDistsN1(bbox, bbox[2, ], longlat) :
#  NA/NaN/Inf em chamada de função externa (argumento 1)

sp.gauss  <- gwr((tab$PERIDOSO~tab$PERREN20),data=tab,coords=mapcents, 
bandwidth=sjc.bw, hatmatrix=TRUE)




More information about the R-sig-Geo mailing list