make_empty_graph: A graph with no edges

Description Usage Arguments Value See Also Examples

View source: R/make.R

Description

A graph with no edges

Usage

1
2
3
make_empty_graph(n = 0, directed = TRUE)

empty_graph(...)

Arguments

n

Number of vertices.

directed

Whether to create a directed graph.

...

Passed to make_graph_empty.

Value

An igraph graph.

See Also

Other determimistic constructors: graph_from_atlas(), graph_from_edgelist(), graph_from_literal(), make_chordal_ring(), make_full_citation_graph(), make_full_graph(), make_graph(), make_lattice(), make_ring(), make_star(), make_tree()

Examples

1
2
make_empty_graph(n = 10)
make_empty_graph(n = 5, directed = FALSE)

Example output

Attaching package: 'igraph'

The following objects are masked from 'package:stats':

    decompose, spectrum

The following object is masked from 'package:base':

    union

IGRAPH 0000000 D--- 10 0 -- 
+ edges from 0000000:
IGRAPH 0000000 U--- 5 0 -- 
+ edges from 0000000:

igraph documentation built on Jan. 8, 2021, 2:19 a.m.