crisp: Crisp the fuzzy membership degrees

View source: R/tools.R

crispR Documentation

Crisp the fuzzy membership degrees

Description

Crisps the fuzzy and possibilistic membership degrees from the fuzzy or possibilistic clustering algorithms.

Usage

crisp(u, method, tv)

Arguments

u

a numeric matrix containing the fuzzy or possibilistic membership degrees of the data objects.

method

a string for selection of the crisping method. The default is max that assigns the data object to the cluster in which the object has maximum membership. The alternative is threshold that assigns the objects to a cluster if its maximum membership degree is greater than tv, a threshold value.

tv

a number for the threshold membership degree. The default is 0.5 with the method is threshold if it is not speficied by the user.

Details

The function crisp produces the crisp or hard membership degrees of the objects in order to place them into only one cluster.

Value

cluster

a numeric vector containing the indexes (labels) of clusters for the maximum membership of the objects.

Author(s)

Zeynel Cebeci

Examples

data(iris)
x <- iris[,1:4]

# Run FCM 
res.fcm <- fcm(x, centers=3)

# Crisp the fuzzy memberships degrees and plot the crisp memberships
cllabels <- crisp(res.fcm$u)
plot(x, col=cllabels)

ppclust documentation built on May 29, 2024, 7:20 a.m.