from Bio.Blast import NCBIXML
xmlfh = open('/home/sb/bioinfo/other.xml') # BLAST output file.
for record in NCBIXML.parse(xmlfh):
    for align in record.alignments:
        print(align.title)    

This code is part of the book "Python for Bioinformatics", by Sebastian Bassi (sbassi@genesdigitales.com). Return to home page.