[Biopython] pass a variable to a blast cmd

Willis, Jordan R jordan.r.willis at Vanderbilt.Edu
Tue Jun 18 15:29:21 UTC 2013


Just literally put the variable right in there.

>> blast_cline = NcbiblastpCommandline(cmd = "blastp", task = "blastp-short",
>>                                        query = inf, matrix = "PAM30",
>>                                        outfmt = "5", db = database,
>>                                        remote = True, comp_based_stats = "0",
>>                                         out = "blast_out.xml") 
On Jun 18, 2013, at 10:15 AM, Frederico Moraes Ferreira <ferreirafm at usp.br> wrote:

> I'm sorry for this stupid question.
> Best,
> Fred
> 
> Em 18-06-2013 11:12, Frederico Moraes Ferreira escreveu:
>> Hi there,
>> Is there a clever way of passing a variable to the blast_cline command like:
>> 
>> blast_cline = NcbiblastpCommandline((cmd = "blastp", task = "blastp-short",
>>                                        query = inf, matrix = "PAM30",
>>                                        outfmt = "5", db = "%s",
>>                                        remote = True, comp_based_stats = "0",
>>                                         out = "blast_out.xml") % database)
>> 
>> or should I have to have one command to each option.
>> Best,
>> Fred
>> 
>> 
>> 
>> 
>> 
>> 
>> _______________________________________________
>> Biopython mailing list  -  Biopython at lists.open-bio.org
>> http://lists.open-bio.org/mailman/listinfo/biopython
>> 
> 
> -- 
> Dr. Frederico Moraes Ferreira
> University of Sao Paulo
> Heart Institute, School of Medicine
> Laboratoy of Immunology
> Av. Dr. Enéas de Carvalho Aguiar, 44
> 05403-900     Sao Paulo - SP
> Brasil
> 
> _______________________________________________
> Biopython mailing list  -  Biopython at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/biopython
> 






More information about the Biopython mailing list