Does Ncbitblastncommandline Reads The Outfmt (Options 6, 7, And 10 ) Correctly?
1
2
Entering edit mode
10.1 years ago
microbeatic ▴ 80

I am trying to call

tblastn_hits = NcbitblastnCommandline(cmd='tblastn',
                                         query=query_handle,
                                         db=db_handle,
                                         num_threads=6,
                                         evalue=0.001,
                                         outfmt="6 qstart qend evalue bitscore",
                                         dbsize=10000000,
                                         out="%s%s.txt" % (result_handle,orf_name))

But, when i run the script, it ignores anything after 6 in outfmt, so the blast results only have default columns. Is this a problem with the Biopython version or i am doing something wrong?

biopython blast blast • 4.4k views
ADD COMMENT
1
Entering edit mode

I'm having the same issue when running blast+ executables straight from command line.

ADD REPLY
4
Entering edit mode
10.1 years ago
Peter 6.0k

You need to quote it, the easiest way would be:

tblastn_hits = NcbitblastnCommandline(cmd='tblastn',
                                     query=query_handle,
                                     db=db_handle,
                                     num_threads=6,
                                     evalue=0.001,
                                     outfmt='"6 qstart qend evalue bitscore"',
                                     dbsize=10000000,
                                     out="%s%s.txt" % (result_handle,orf_name))

Here I am using single quotes for the Python string, which means I can use double quotes inside the string.

ADD COMMENT
0
Entering edit mode

Problem with qcovs in blast outfmt 6 ... I'm so grateful to you :D

Seriously , I can't thank you enough.

ADD REPLY
0
Entering edit mode

Yes, thank you! I was having this problem on blast+ on the command line when combining it with GNU Parallel.

ADD REPLY

Login before adding your answer.

Traffic: 2370 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6