silhouette.score {SOMMD} | R Documentation |
Silhouette score
Description
Function to compute the silhouette score for the clustering of SOM neurons
Usage
silhouette.score(
SOM,
dist_clust = "euclidean",
clust_method = "complete",
interval = seq(2, 30)
)
Arguments
SOM |
the SOM object to cluster |
dist_clust |
the metric for the distance calculation |
clust_method |
the method for the clustering (passed to the hclust function |
interval |
the cluster number on which the silhouette score will be computed |
Value
A vector with the silhouette scores for all the frames
Author(s)
Stefano Motta stefano.motta@unimib.it
Examples
#Read example SOM data
som_model <- readRDS(system.file("extdata", "SOM_HIFa.rds", package = "SOMMD"))
#Compute the silhouette profile
sil_score <- silhouette.score(som_model, clust_method="complete", interval=seq(2,8))
[Package SOMMD version 0.1.2 Index]