is_directed: Check whether a graph is directed

Description Usage Arguments Value See Also Examples

View source: R/interface.R

Description

Check whether a graph is directed

Usage

1

Arguments

graph

The input graph

Value

Logical scalar, whether the graph is directed.

See Also

Other structural queries: [.igraph(), [[.igraph(), adjacent_vertices(), are_adjacent(), ends(), get.edge.ids(), gorder(), gsize(), head_of(), incident_edges(), incident(), neighbors(), tail_of()

Examples

1
2
3
4
5
g <- make_ring(10)
is_directed(g)

g2 <- make_ring(10, directed = TRUE)
is_directed(g2)

Example output

Attaching package: 'igraph'

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

    decompose, spectrum

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

    union

[1] FALSE
[1] TRUE

igraph documentation built on Jan. 5, 2022, 1:09 a.m.

Related to is_directed in igraph...