This set of functions lets the user query different aspects of the graph itself. They are all concerned with wether the graph implements certain properties and will all return a logical scalar.

graph_is_simple()

graph_is_directed()

graph_is_bipartite()

graph_is_connected()

graph_is_tree()

graph_is_forest()

graph_is_dag()

graph_is_chordal()

graph_is_complete()

graph_is_isomorphic_to(graph, method = "auto", ...)

graph_is_subgraph_isomorphic_to(graph, method = "auto", ...)

Arguments

graph

The graph to compare structure to

method

The algorithm to use for comparison

...

Arguments passed on to the comparison methods. See igraph::is_isomorphic_to() and igraph::is_subgraph_isomorphic_to()

Value

A logical scalar

Functions

  • graph_is_simple: Is the graph simple (no parallel edges)

  • graph_is_directed: Is the graph directed

  • graph_is_bipartite: Is the graph bipartite

  • graph_is_connected: Is the graph connected

  • graph_is_tree: Is the graph a tree

  • graph_is_forest: Is the graph an ensemble of multiple trees

  • graph_is_dag: Is the graph a directed acyclic graph

  • graph_is_chordal: Is the graph chordal

  • graph_is_complete: Is the graph fully connected

  • graph_is_isomorphic_to: Is the graph isomorphic to another graph. See igraph::is_isomorphic_to()

  • graph_is_subgraph_isomorphic_to: Is the graph an isomorphic subgraph to another graph. see igraph::is_subgraph_isomorphic_to()

Examples

gr <- create_tree(50, 4) with_graph(gr, graph_is_tree())
#> [1] TRUE