Skip to main content
`Ctrl`+`K`

# skbio.tree.TreeNode.assign_ids

TreeNode.assign_ids()

  Assign topologically stable unique IDs to all nodes of the tree.

  See also

  `find_by_id`
  `postorder`

  Notes

  This method assigns unique IDs to all nodes of the tree via a postorder traversal. The IDs are incremental integers starting from 0. The order is topologically stable. Following the call, all nodes in the tree will have their `id` attribute set.