search for: spnamedvec

Displaying 3 results from an estimated 3 matches for "spnamedvec".

2005 Nov 17
1
Morans I for Spatial Surveillance
...ble if anyone has tips for this I would alo appreciate it as I am rather new to R! Thanks Serryn T1<-read.dbf("ob.dbf") N <- colnames(T1) T2nb <- read.gal("PC.gal",override=TRUE) col.W <- nb2listw(T2nb, style="W") for(i in seq(N)) { Vec1 <- spNamedVec(N[i+7], T1) Svec1<-sum(Vec1) ifelse ( Svec1> 0, res[i]<-moran.test(spNamedVec(N[i+7], T1), col.W, zero.policy=TRUE), res[i]<-"NULL") } print(res) [[alternative HTML version deleted]]
2004 Jun 18
1
how to store estimates results as scalars of a matrix?
...#39;m not sure how I could do this using R. Any help will be much appreciated. All the very best, JP coords2 <- as.matrix(jcdist.data[1:87, 6:7]) col.tri.nb<-tri2nb(coords2) for(n in c(1,88,175,262,349)) { f<- n+86 work <- jcdist.data[n:f, 10:12] res <-moran.test(spNamedVec("res1", work), nb2listw(col.tri.nb, style="W")) moran<-res$estimate[1] upper<-res$estimate[1] + (qnorm(0.025, lower.tail=FALSE) *sqrt(res$estimate[3])) lower<-res$estimate[1] - (qnorm(0.025, lower.tail=FALSE) *sqrt(res$estimate[3])) print(moran)...
2007 Feb 06
2
How to do "moran's I test"?
I want to do "moran's I test" in R language. I try to use "gearymoran" in Package "ade4","moran" in Package "spdep", and Moran.I in Package "ape". But I do not know how to do it because data format is different. My data: x y dbh 111.03 10.7 7 118.11 0.28 1.2 165.36 0.36 8.4