imgClassif {RclusTool} | R Documentation |
Images clustering
Description
Sort images (if available) in different directories according to a clustering result.
Usage
imgClassif(data.sample, imgdir, method, user.name = "")
Arguments
data.sample |
list containing features, profiles and clustering results. |
imgdir |
character vector specifying the path of the images directory. |
method |
character vector specifying the clustering method (already performed) to use. |
user.name |
character vector specifying the user name. |
Details
imgClassif sorts images (if available) in different directories according to a clustering result
Value
images files in the different directories, csv file containing the detail.
See Also
Examples
dat <- rbind(matrix(rnorm(100, mean = 0, sd = 0.3), ncol = 2),
matrix(rnorm(100, mean = 2, sd = 0.3), ncol = 2),
matrix(rnorm(100, mean = 4, sd = 0.3), ncol = 2))
tf1 <- tempfile()
write.table(dat, tf1, sep=",", dec=".")
rep <- system.file("extdata", package="RclusTool")
imgdir <- file.path(rep, "img_example")
dir.results <- tempdir()
x <- importSample(file.features=tf1, dir.images=imgdir, dir.save=dir.results)
x <- computeUnSupervised(x, K=3, method.name="K-means")
imgClassif(x, imgdir, method = "K-means_preprocessed")
[Package RclusTool version 0.91.6 Index]