I use NetworkX to generate graphs of some noisy data. I would like to “clear” the chart by deleting branches that are false, and I hope to avoid re-creating the wheel.
For example, a related image shows an example of a set of graphs, since the colored nodes are connected by gray lines. I would like to trim the nodes / edges indicated by white cells: http://www.broadinstitute.org/~mbray/example_tree.png
Essentially, the nodes / edges to be removed are branches, typically only a few nodes (<3) in length. Having deleted them, I hope to have a tree with minimal branching, but the branches that remain "fit" for a long time.
Before starting the development of code for checking subtrees for deletion, are there NetworkX functions that can be used for this purpose?
networkx
braymp
source share