[BioPython] Parsing BLAST

Alex Garbino agarbino at gmail.com
Wed Aug 27 17:12:58 UTC 2008


Hello,

I'm following the tutorials to do BLAST queries, however, I can't get
the Blast object to work.

I've downloaded the blast search, saved it in XML, etc, as the
tutorial does. However, when I get to the step where I'm trying to get
actual data out, it fails (the for loops part).
Here is a simplified version that illustrates the problem:

for x in blast_record.alignments:
    print alignment.title

Traceback (most recent call last):
  File "<input>", line 2, in <module>
NameError: name 'alignment' is not defined

-----------------------

blast_record contains lots of data, I just can't seem to be able to
get anything out of it... what am I doing wrong?

Thanks,
Alex



More information about the Biopython mailing list