docs: def traverse_rootdistorder(self, ascending=True, leaves=True, internal=True):
          '''Perform a traversal of the ``Node`` objects in the subtree rooted at this ``Node`` in either ascending (``ascending=True``) or descending (``ascending=False``) order of distance from this ``Node``
  
          Args:
              ``ascending`` (``bool``): ``True`` to perform traversal in ascending distance from the root, otherwise ``False`` for descending
  
              ``leaves`` (``bool``): ``True`` to include leaves, otherwise ``False``
  
              ``internal`` (``bool``): ``True`` to include internal nodes, otherwise ``False``
          '''
          if not isinstance(ascending, bool):
              raise TypeError("ascending must be a bool")
          nodes = list(); dist_from_root = dict()
          for node in self.traverse_preorder():
              if node == self:
                  d = 0
              else:
                  d = dist_from_root[node.parent] + node.edge_length
              dist_from_root[node] = d
              if (leaves and node.is_leaf()) or (internal and not node.is_leaf()):
                  nodes.append((d,node))
          nodes.sort(reverse=(not ascending))
          for e in nodes:
              yield e