R Under development (unstable) (2024-02-07 r85873 ucrt) -- "Unsuffered Consequences" Copyright (C) 2024 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > library(SillyPutty) > > set.seed(3568) > nObj <- 110 > fake <- matrix(rnorm(50*nObj), nrow=nObj, ncol = 50) > dimnames(fake) <- list(paste("Sample", 1:nObj, sep=''), + paste("Feature", 1:50, sep='')) > dis <- dist(fake) > labels <- sample(6, nObj, replace = TRUE) > names(labels) <- rownames(fake) > x <- SillyPutty(labels, dis) > plot(x@silhouette, col=1:6) > > mds <- cmdscale(dis) > plot(mds, pch=16, col=x@cluster, cex=2) > > set.seed(8732) > y <- RandomSillyPutty(dis, 6, N = 100) Warning messages: 1: In SillyPutty(START, distobj, ...) : Early halt because of possible infinite loop. 2: In SillyPutty(START, distobj, ...) : Early halt because of possible infinite loop. 3: In SillyPutty(START, distobj, ...) : Early halt because of possible infinite loop. > > sr <- summary(y) > sr Mean Silhouette Widths: Min. 1st Qu. Median Mean 3rd Qu. Max. 0.02550 0.02940 0.03039 0.03057 0.03189 0.03487 > > proc.time() user system elapsed 4.75 1.34 6.06