The method employs spectral density of eigenvalues from Laplacian in that for each, we have corresponding spectral density ρ(w) as a sum of narrow Lorentz distributions with bandwidth parameter. Since it involves integration of a function over the non-compact domain, it may blow up to infinity and the code automatically aborts the process.
nd.csd(A, out.dist =TRUE, bandwidth =1)
Arguments
A: a list of length N containing (M×M) adjacency matrices.
out.dist: a logical; TRUE for computed distance matrix as a dist object.
bandwidth: common bandwidth of positive real number.
Returns
a named list containing
D: an (N×N) matrix or dist object containing pairwise distance measures.
spectra: an (N×M−1) matrix where each row is top-M−1 vibrational spectra.
Examples
## load example datadata(graph20)## compute distance matrixoutput = nd.csd(graph20, out.dist=FALSE, bandwidth=1.0)## visualizeopar = par(no.readonly=TRUE)par(pty="s")image(output$D[,20:1], main="two group case", axes=FALSE, col=gray(0:32/32))par(opar)