TreeNode.
subsets
()[source]¶Return all sets of names that come from self and its descendants
State: Experimental as of 0.4.0.
Compute all subsets of tip names over self, or, represent a tree as a set of nested sets.
A frozenset of frozensets of str
frozenset
See also
Examples
>>> from skbio import TreeNode
>>> tree = TreeNode.read(["(((a,b)c,(d,e)f)h)root;"])
>>> subsets = tree.subsets()
>>> len(subsets)
3