How to do it...

Take a look at the following steps:

  1. Let's load all the phylogenetic data:
from copy import deepcopyfrom Bio import Phyloebola_tree ='my_ebola.nex', 'nexus') = 'Ebolavirus tree'ebola_simple_tree ='ebola_simple.nex', 'nexus') = 'Ebolavirus simplified tree'

For all of the trees that we read, we will change the name of the tree, since the name will be printed later.

  1. Now, we can draw ASCII representations of the trees:

The ASCII representation of the simplified genus tree is shown in the following diagram. Here, we will not print the complete version because it will take several pages, but if you run ...

Get Bioinformatics with Python Cookbook - Second Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.