SpatialPixelsDataFrame-class for further information on the class SpatialPixelsDataFrame
Examples
data(lynxjura)sa <- lynxjura$map[,1]## build an image with separate componentssa[[1]][sa[[1]]<50]<-NA## show the connected componentsimage(sa)image(labcon(sa))