This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Adding -type arguments of blastn in Bioperl

I need to run a blast for small query sequence in bioperl. The way to do it in blast standalone program is by adding

./blastn -db nt -remote -query test2.seq -task "blastn-short" -out test2.out

Is there a way to add -task arguments in BioPerl?

Thank you

alignment sequence

1 answer

Check https://bioperl.org/howtos/BlastPlus_HOWTO.html

Thank you sir for responding. I tried

$result = $fac->blastn( -query => 'myquery.fasta',
                          -task -> 'blastn-short'
                          -outfile => 'result01.txt',
                          -outformat => 9)

It does not work.

in case you copy/pasted this there's a typo after -task -> must be =>:

$result = $fac->blastn( -query => 'myquery.fasta', -task -> 'blastn-short' -outfile => 'result01.txt', -outformat => 9)
                                                         /\

Sorry about the typo. I didn't copy paste it, that's why. Anyway, it does not work with it.

from a short glimpse it seems that either you have to call it via blastn-short or specify task using method_args:

$result = $fac->blastn-short( -query => 'myquery.fasta', -outfile => 'result01.txt', -outformat => 9)

$result = $fac->blastn( -query => 'query_seqs.fas',
                    -outfile => 'query.bls',
                    -method_args => [ -task => "blastn-short"
                                      -num_alignments => 10,
                                      -evalue => 100 ]);

Bear in mind I'm only guessing

If an answer was helpful, you should upvote it; if the answer resolved your question, you should mark it as accepted. You can accept more than one answer if they all work.

Upvote|Bookmark|Accept

Log in to answer this question.