Skip to content
Prev 7133 / 29559 Next

Moving window correlation

On Tue, 2009-12-08 at 21:54 +0100, Jaime R. Garcia M. wrote:
# Small correction

v = sapply(nb, function(i) cor(G1 at data[i,], G2 at data[i,]))

#  And in this case the result should be a numeric vector

coordinates(v) = coordinates(G1)
gridded(v) = TRUE
fullgrid(v) = TRUE
_______________________________________________