This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Help To Blast Sequences Against Drosophila Genome In Biopython

Hi,

I am trying to blast certain sequences (in fasta files) against the drosophila genome using the qblast operation provided in BioPython. From the documentations, I have figured out that the second argument that you are supposed to enter in qblast refers to the database against which you are trying to BLAST. I went through the BioPython documentation, but wasnt able to understand how to blast against the drosophila genome. That is, I couldn't figure out the specific (second) argument that I need to enter in qblast to BLAST against the drosophila genome. Can someone provide me an example that shows how to BLAST against the drosophila genome using the NCBIWWW.qblast tool?

Thanks!

biopython blast

1 answer

This is basically just a wrapper around the web QBLAST server. If you view the source you can see what it does http://biopython.org/DIST/docs/api/Bio.Blast.NCBIWWW-pysrc.html. If you want to BLAST against the Drosophila melanogaster reference genome, I believe you should set database='refseq_genomic' and add an extra parameter organism='7227' where 7227 is the taxonomic ID for Drosophila melanogaster.

Something like:

dmel_qblast = NCBIWWW.qblast(program="blastn", database="refseq_genomic", sequence=input_sequence, organism="7227")

Perhaps there has been a change since on NCBI's side since this posting, but the correct way to do this would be through the "entrez_query" argument:

NCBIWWW.qblast(program="blastn", database="refseq_genomic", sequence=input_sequence, entrez_query="txid7227[ORGN]")

Log in to answer this question.