Learn R Programming

RclusTool (version 0.91.61)

computeGaussianSimilarityZP: Gaussian similarity

Description

Compute a similarity matrix thanks a Gaussian kernel for which the parameters are self-tuned (according to Zelnik-Manor and Perona, 2004).

Usage

computeGaussianSimilarityZP(dat, k = 7)

Value

sim similarity matrix.

Arguments

dat

numeric matrix of data (point by line).

k

number of neighbour for the computation of local sigma (smooth parameter of Gaussian kernel).

Details

computeGaussianSimilarityZP returns a similarity matrix computed thanks a Gaussian kernel for which the parameters are self-tuned (according to Zelnik-Manor and Perona, 2004)

References

L. Zelnik-Manor, P. Perona, Self tuning spectral clustering, Adv. Neural Inf. Process. Systems (2004), pp. 1601-1608.

See Also

computeGaussianSimilarity

Examples

Run this code
require(grDevices)

dat <- rbind(matrix(rnorm(100, mean = 0, sd = 0.3), ncol = 2), 
           matrix(rnorm(100, mean = 2, sd = 0.3), ncol = 2), 
           matrix(rnorm(100, mean = 4, sd = 0.3), ncol = 2))

sim <- computeGaussianSimilarityZP(dat, 10)

pal <- colorRampPalette(c("blue", "red"))
image(sim, col = pal(10))

Run the code above in your browser using DataLab