computeGaussianSimilarityZP: Gaussian similarity

Description Usage Arguments Details Value References See Also Examples

View source: R/codeSpectral.R

Description

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

Usage

1

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)

Value

sim similarity matrix.

References

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

See Also

computeGaussianSimilarity

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
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))

RclusTool documentation built on Feb. 4, 2020, 5:08 p.m.