ivy.autocollapse module¶
For drawing big trees. Calculate which clades can be ‘collapsed’ and displayed with a placeholder.
TODO: test and develop this module further
-
ivy.autocollapse.
autocollapse
(root, collapsed=None, keep_visible=None, max_visible=1000)[source]¶ traverse a tree and find nodes that should be collapsed in order to satify max_visible
collapsed is a set object for storing collapsed nodes
keep_visible is a set object of nodes that should not be placed in collapsed