cs | R Documentation |
Computes the Separation/Compactness (Bensaid et al, 1996) ratio index in order to validate the result of a fuzzy and/or possibilistic clustering analysis.
cs(x, u, v, m, t=NULL, eta, tidx="f")
x |
an object of class ‘ppclust’ containing the clustering results from a fuzzy clustering algorithm in the package ppclust. Alternatively, a numeric data frame or matrix containing the data set. |
u |
a numeric data frame or matrix containing the fuzzy membership values. It should be specified if |
v |
a numeric data frame or matrix containing the cluster prototypes. It should be specified if |
t |
a numeric data frame or matrix containing the cluster prototypes. It should be specified if |
m |
a number specifying the fuzzy exponent. It should be specified if |
eta |
a number specifying the typicality exponent. It should be specified if |
tidx |
a character specifying the type of index. The default is ‘f’ for fuzzy index. The other options are ‘e’ for extended and ‘g’ for generalized index. |
The validity-guided (re)clustering (VGC) algorithm uses cluster-validity information to guide a fuzzy (re)clustering process toward better solutions. It starts with a partition generated by a soft or fuzzy clustering algorithm. Then it iteratively alters the partition by applying split-and-merge operations to the clusters (Bensaid, 1996). The authors proposed the Compactness / Separation (CS) ratio index in order to validate the results of VGC. The formula of CS index is:
I_{CS}=∑\limits_{j=1}^k \frac{∑\limits_{i=1}^n u_{ij}^m \; d_{ij}^2}{∑\limits_{i=1}^n u_{ij} \; ∑\limits_{l=1}^k||\vec{v_j} - \vec{v_l}||^2}
A lower value of I_{CS} indicates a better clustering.
cs |
CS index value if |
cs.e |
extended CS index value if |
cs.g |
generalized CS index value if |
Zeynel Cebeci
Bensaid, A.M., Hall, L.O., Bezdek, J.C., Clarke, L.P., Silbiger, M.L., Arrington, J.A. & Murtagh, R.F. (1996). Validity-guided (re)clustering with applications to image segmentation, IEEE Transactions on Fuzzy Systems, 4(2):112-123. <10.1109/91.493905>
allindexes
,
apd
,
cl
,
cwb
,
fhv
,
fs
,
kpbm
,
kwon
,
mcd
,
mpc
,
pbm
,
pc
,
pe
,
si
,
tss
,
ws
,
xb
# Load the dataset iris and use the first four feature columns data(iris) x <- iris[,1:4] # Run FCM algorithm in the package ppclust res.fcm <- ppclust::fcm(x, centers=3) # Compute the CS index using res.fcm, which is a ppclust object idx <- cs(res.fcm) print(idx) # Compute the CS index using X, U and V matrices idx <- cs(res.fcm$x, res.fcm$u, res.fcm$v) print(idx) # Run UPFCM algorithm in the package ppclust res.upfc <- ppclust::upfc(x, centers=3) # Compute the generalized CS index using res.upfc, which is a ppclust object idx <- cs(res.upfc, tidx="g") print(idx)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.