gs.embed.lse: Spectral Embedding of the Laplacian of a Graph

Description Usage Arguments Details Value Author(s) References Examples

Description

Spectral decomposition of Laplacian matrices of graphs.

Usage

1
gs.embed.lse(g, k = NULL, edge.attr = NULL)

Arguments

g

an igraph object or an nxn adjacency matrix with n vertices.

edge.attr

if g is a igraph, the name of the attribute to use for weights. Defaults to NULL, which assumes the graph is binary.

  • is.null(edge.attr) assumes unweighted.

  • is.character(edge.attr) assumes weighted with weights given by edge.attr.

Details

This function computes a k-dimensional Euclidean representation of the graph based on its Laplacian matrix, L. This representation is computed via the singular value decomposition of the Laplacian matrix.

Value

A list containing the following:

X

an n by k matrix indicating the estimated latent positions, where n is the number of vertices of g.

Y

NULL if g is undirected. If g is directed, Y is a n by k matrix indicating the second half of the latent positions.

D

The eigenvalues (for undirected graphs) or the singular values (for directed graphs) associated with the latent positions.

Author(s)

Eric Bridgeford ericwb95@gmail.com

References

Sussman, D.L., Tang, M., Fishkind, D.E., Priebe, C.E. A Consistent Adjacency Spectral Embedding for Stochastic Blockmodel Graphs, Journal of the American Statistical Association, Vol. 107(499), 2012

Examples

1
2
3
4
5
6
## A small graph
lpvs <- matrix(rnorm(200), 20, 10)
lpvs <- apply(lpvs, 2, function(x) { return (abs(x)/sqrt(sum(x^2))) })
RDP <- sample_dot_product(lpvs)
embed <- embed_laplacian_matrix(RDP, 5)
TODO ebridge2

neurodata/graphstats documentation built on May 14, 2019, 5:19 p.m.