INNER CODE UNIT · Python
summarize
pybel/pybel · src/pybel/cli.py:241
def summarize(graph: BELGraph):
"""Summarize a graph."""
_print_summary(graph)
def _print_summary(graph: BELGraph, ticks: bool = False):
if not ticks:
click.secho("Summary", fg="red", bold=True)
graph.summarize()
unused_namespaces = get_unused_namespaces(graph)
if unused_namespaces:
click.secho(
f"\nUnused Namespaces ({len(unused_namespaces)}/{len(graph.defined_namespace_keywords)})",
fg="red",
bold=True,
)
if ticks: