TreeNode.
root
()[source]¶Returns root of the tree self is in
State: Experimental as of 0.4.0.
Returns: | The root of the tree |
---|---|
Return type: | TreeNode |
Examples
>>> from skbio import TreeNode
>>> tree = TreeNode.read(["((a,b)c,(d,e)f)root;"])
>>> tip_a = tree.find('a')
>>> root = tip_a.root()
>>> root == tree
True