Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

values or names on tree branches (graph)

Hi

How can I make appear names (or,and) numerical values on the branches ?.

#https://ask.sagemath.org/question/43106/preserving-the-rooted-tree-layout-in-graphs/
G=Graph({1:[2,3],2:[4,5],3:[6,7]})
G.weighted(False)
G.show(layout='tree',tree_root=1)
show(G.vertices())