# 'pam' settings combining number of clusters K={2,3}, and dissimilarities {euclidean, manhattan}
A <- mset_pam(K = c(2,3), metric = c("euclidean", "manhattan"))
# select setup 1: K=2, metric = "euclidean"
m <- A[[1]]
print(m)
# cluster with the method set in 'm'
data("banknote")
dat <- banknote[-1]
fit1 <- m$fn(dat)
fit1
class(fit1)
# if only cluster parameters are needed
fit1b <- m$fn(dat, only_params = TRUE)
fit1b
Run the code above in your browser using DataLab