Skip to contents

Graph attributes of a graph

Usage

graph_attr(graph, name)

Arguments

graph

Input graph.

name

The name of attribute to query. If missing, then all attributes are returned in a list.

Value

A list of graph attributes, or a single graph attribute.

Examples

g <- make_ring(10)
graph_attr(g)
#> $name
#> [1] "Ring graph"
#> 
#> $mutual
#> [1] FALSE
#> 
#> $circular
#> [1] TRUE
#> 
graph_attr(g, "name")
#> [1] "Ring graph"