[R-sig-Geo] package 'raster' function 'clump'

Benno N. Dillinger benno.dillinger at gmail.com
Sat Jun 22 18:13:42 CEST 2013


Dear all,

are there any issues related to function 'clump', eg due to the update 
to the 3.0 version of R?

I tried to apply the function on a RasterLayer containing values 1-5. As 
a result it returns a RasterLayer containing value 1, only.

Thanks in advance.

example:

r <- raster(ncol = 10, nrow = 10)
r[] <- sample(x, size = 100, replace = TRUE)#1:ncell(r)
as.raster(r)
summary(r)


k <- clump(r, directions = 4, gaps = FALSE)
k

-- 

B. N. Dillinger, Bakk.techn.

Tel.: +43 (0)680 - 2328849



More information about the R-sig-Geo mailing list