awcd | R Documentation |
Computes the Average Within-Cluster Distance (Krishnapuram & Freg, 1992) to validate the result of a fuzzy and/or possibilistic clustering analysis.
awcd(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. |
Average Within-Cluster Distance (AWCD) is defined as:
I_{AWCD}=\frac{1}{n \; k} \frac{∑\limits_{i=1}^n u_{ij}^m \; d_{ij}^2}{∑\limits_{i=1}^n u_{ij}^m}
As the I_{AWCD} monotonically decreases with the number of clusters. A knee in the curve of I_{AWCD} as a function of k indicates a good fuzzy partition.
awcd |
AWCD index value if |
awcd.e |
extended AWCD index value if |
awcd.g |
generalized AWCD index value if |
Zeynel Cebeci
Krishnapuram, R. & Freg, C. P. (1992). Fitting an unknown number of lines and planes to image data through compatible cluster merging. Pattern Recognition, 25(4):385-400. <doi:10.1016/0031-3203(92)90087-Y>
allindexes
,
apd
,
cs
,
cwb
,
fhv
,
fs
,
kpbm
,
kwon
,
mcd
,
mpc
,
pbm
,
pc
,
pe
,
sc
,
si
,
tss
,
ws
,
xb
# Load the dataset iris data(iris) x <- iris[,1:4] # Run FCM algorithm in the package ppclust res.fcm <- ppclust::fcm(x, centers=3) # Compute the AWCD index using res.fcm, which is a ppclust object idx <- awcd(res.fcm) print(idx) # Compute the AWCD index using X, U and V matrices idx <- awcd(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 AWCD index using res.upfc, which is a ppclust object idx <- awcd(res.upfc, tidx="g") print(idx)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.