Sys.unsetenv("LARES_FONT") # Temporal
data("iris")
df <- subset(iris, select = c(-Species))
df <- df[sample(nrow(df)), ]
# Calculate and plot
result <- clusterVisualK(df, ks = 2:4)
plot(result$plot)
# You can use the data generated as well
lapply(result$data, function(x) head(x$cluster, 10))
Run the code above in your browser using DataLab