Re: [R] black cluster in salt and pepper image

2010-03-09 Thread Carl Witthoft
You might also want to look at the ImageJ application, http://rsb.info.nih.gov/ij/ which IIRC has a bunch of tools designed to pick out clusters, dots, etc. Carl __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEAS

Re: [R] black cluster in salt and pepper image

2010-03-08 Thread Gregoire Pau
Hello, The function bwlabel() in the Bioconductor package EBImage, extracts the connected components of an image. Denoting your binary matrix by x, the following code gives you the first 10 largest clusters (in size). > library(EBImage) > y = bwlabel(x) > sort(table(y), dec=TRUE)[1:10] See h

[R] black cluster in salt and pepper image

2010-03-08 Thread Sylvain Sardy
Hi, on a lattice, I have binary 0/1 data. 1s are rare and may form clusters. I would like to know the size/length of largest cluster. Any help warmly welcome, Sylvain. __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help