[Biopython] fasta fail

Peter biopython at maubp.freeserve.co.uk
Wed Dec 1 16:06:28 UTC 2010


On Wed, Dec 1, 2010 at 3:57 PM, Liam Thompson <dejmail at gmail.com> wrote:
> Hi Peter
>
> Apologies, it seems each of the records in the list is a SeqRecord.
>
>>>> type(final_seq[0])
> <class 'Bio.SeqRecord.SeqRecord'>
>
>>>> type(final_seq)
> <type 'list'>
>
> SeqIO seems to process the sequence fine, it just can't seem
> to write it.
>
> thanks
> Liam

If final_seq is a list of SeqRecord objects, then Bio.SeqIO.write
should be able to save it - assuming they all have sequences.
What does this do?,

for record in final_seq: print record.id, type(record.seq)

Peter



More information about the Biopython mailing list