EdgeTags

EdgeTags[g]

gives the list of tags for all edges in the graph g.

EdgeTags[g,{u,v}]

gives the list of tags for edges between u and v.

Details

  • EdgeTags[g] returns the list of edge tags in the order used by the graph g.
  • For a directed graph g, EdgeTags[g,{u,v}] gives tags for edges from u to v.
  • Null is used to indicate the absence of a tag in an edge.
  • When a graph g has no edge with tags, EdgeTags[g] gives an empty list.

Examples

open allclose all

Basic Examples  (1)

The list of edge tags for an explicitly constructed graph:

The list of edge tags between 1 and 2:

Scope  (5)

EdgeTags works with undirected graphs:

Directed graphs:

Multigraphs:

Mixed graphs:

EdgeTags works with large graphs:

Properties & Relations  (4)

EdgeCount can be found using EdgeTags in a tagged graph:

Tags in EdgeTags are given in the same order their edges are entered for Graph:

EdgeTags gives an empty list for input that is not tagged graphs:

EdgeTags can be found using EdgeList in IndexEdgeTaggedGraph:

Possible Issues  (2)

Null is used to indicate the absence of a tag in an edge:

EdgeTags gives an empty list for a graph with no edge tags:

Introduced in 2020
 (12.1)