labelClusters.Rd
This will give a unique ID to each connected component 1 through N of size > minClusterSize
labelClusters(
imagein,
minClusterSize = 50,
minThresh = 1e-06,
maxThresh = 1,
fullyConnected = FALSE
)
labeled cluster image is output
img <- antsImageRead(getANTsRData("r16"))
timgFully <- labelClusters(img, 10, 128, 150, TRUE)
timgFace <- labelClusters(img, 10, 128, 150, FALSE)
if (FALSE) { # \dontrun{
plot(img, timgFace)
plot(img, timgFully)
} # }