Glycan.label_branches curently assigns letter labels based on the order it visits a branch, but it should assign labels closer to a to the longer branch.
It is hard to know which branch is longer at the beginning of the label_branches method, which also computes branch lengths, so perhaps switch this to a two pass algorithm that finds branch length and then assigns labels accordingly.
Glycan.label_branches
curently assigns letter labels based on the order it visits a branch, but it should assign labels closer toa
to the longer branch.It is hard to know which branch is longer at the beginning of the
label_branches
method, which also computes branch lengths, so perhaps switch this to a two pass algorithm that finds branch length and then assigns labels accordingly.