graph.embedding: Embed Graph in 2D or 3D Space

View source: R/graph_embedding_spectrum.R

graph.embeddingR Documentation

Embed Graph in 2D or 3D Space

Description

Embed Graph in 2D or 3D Space

Usage

graph.embedding(
  adj.list,
  weights.list = NULL,
  invert.weights = TRUE,
  dim = 2,
  method = c("fr", "kk"),
  verbose = FALSE
)

Arguments

adj.list

Adjacency list representation of a graph.

weights.list

Optional edge-weight list aligned with adj.list.

invert.weights

Logical; invert weights for Fruchterman-Reingold layout.

dim

Embedding dimension, either 2 or 3.

method

Layout method, "fr" or "kk".

verbose

Logical; print timing messages.

Value

Numeric layout matrix with one row per embedded vertex.


dgraphs documentation built on Aug. 21, 2026, 1:08 a.m.