[Biopython] BLAST database access

Peter biopython at maubp.freeserve.co.uk
Tue Jan 26 12:59:25 UTC 2010


On Tue, Jan 26, 2010 at 3:58 AM, xyz <mitlox at op.pl> wrote:
> Peter wrote:
>>>
>>> How could I retrieve the sequence which belong to subject id
>>> from BLAST database with BioPython?
>>>
>>
>> Are you using a local BLAST database, or an online one?
>> If online, I would try using the hit ID to search via the NCBI
>> Entrez interface, see the Bio.Entrez chapter in our tutorial.
>> If the database is local, then the NCBI provides a tool as
>> part of the BLAST suite for this called fastacmd.
>>
>> Peter
>
> Thank you. I could retrieve the sequences from a local BlastDB with
> fastacmd, but I have some local BlastDBs which do not have any index,
>  because they were created without using the -o T option in formatdb.
>
> How could I retrieve the sequences from local BlastDBs without index?
>
> Thank you in advance.

That sounds harder... do you still have the original FASTA file
used to build the BLASTDB? If so, just index that - for example
using the Bio.SeeqIO.convert() functionality in Biopython 1.52
or later.

Peter




More information about the Biopython mailing list