graph_from_data_frame: Creating igraph graphs from data frames

graph_from_data_frameR Documentation

Creating igraph graphs from data frames

Description

This function and all of its descriptions have been obtained from the igraph package.

Usage

graph_from_data_frame(d, directed = TRUE, vertices = NULL)

Arguments

d

A data frame containing a symbolic edge list in the first two columns. Additional columns are considered as edge attributes. Since version 0.7 this argument is coerced to a data frame with as.data.frame.

directed

Logical scalar, whether or not to create a directed graph.

vertices

A data frame with vertex metadata, or NULL. Since version 0.7 of igraph this argument is coerced to a data frame with as.data.frame, if not NULL.

Value

An igraph graph object.

See Also

graph_from_adjacency_matrix for a complete description on this function

Other network_reconstruction functions: graph_from_adjacency_matrix(), graph_from_incidence_matrix(), sif2igraph()

Examples

MyData <- coexpression.data
My_graph <- graph_from_data_frame(d=MyData)

influential documentation built on Aug. 6, 2022, 9:05 a.m.