Using an adjacency matrix object, generate a graph of class dgr_graph.
from_adj_matrix(
x,
mode = "undirected",
weighted = FALSE,
use_diag = TRUE,
graph_name = NULL,
write_backups = FALSE,
display_msgs = FALSE
)A square matrix object serving as the adjacency matrix.
The method in which to interpret the input adjacency matrix.
Options include: undirected, directed, upper, lower, max, min,
and plus.
Whether to create a weighted graph from the adjacency matrix.
Whether to use the diagonal of the adjacency matrix in
calculations. If TRUE then the diagonal values will be included as is. If
FALSE then the diagonal values will be replaced with zero values before
inclusion in any calculations.
An optional string for labeling the graph object.
An option to write incremental backups of changing graph
states to disk. If TRUE, a subdirectory within the working directory will
be created and used to store RDS files. The default value is FALSE so
one has to opt in to use this functionality.
An option to display messages primarily concerned with
changes in graph selections. By default, this is FALSE.
A graph object of class dgr_graph.