Question: EMBOSS needle question
gravatar for mossig89
2.9 years ago by
mossig890 wrote:


I'm new to biopython and trying to run the example provided by the biopython documentation section 6.4.5  EMBOSS needle and water:


 from Bio.Emboss.Applications import NeedleCommandline
 needle_cline = NeedleCommandline(asequence="alpha.fasta", bsequence="beta.fasta",
                                  gapopen=10, apextend=0.5,outfile="needle.txt")

I have created two .fasta files and saved two sequences in FASTA format and named the files alpha.fasta and beta.fasta respectively in the same directory as the script containing the above given example. whenever it executes the last line ("stdout,stderr=needle_cline()") it's giving the following error:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Anaconda\lib\site-packages\Bio\Application\", line 513, in __call__
    stdout_str, stderr_str)
Bio.Application.ApplicationError: Non-zero return code 1 from 'needle -outfile=needle.txt -asequence=alpha.fasta -bsequence=beta.fasta -gapopen=10 -gapextend=0.5', message "'needle' is not recognized as an internal or external command,"

I can't figure out why I'm not able to run this simple example, also it is not creating the output file named "needle.txt"

Thanks in advance


alignment • 1.7k views
ADD COMMENTlink modified 2.7 years ago by cts1.5k • written 2.9 years ago by mossig890
gravatar for cts
2.7 years ago by
cts1.5k wrote:

Have you installed emboss separately and is it in your path? Biopython is saying that 'needle' is not a recognized command, which suggests to me that it is not installed. A quick test for this is at your command line type 'needle' and then enter. If you get a message like 'command not found' then you need to install emboss

ADD COMMENTlink written 2.7 years ago by cts1.5k

There was a previous answer and comment thread suggesting that "not installed" is the problem. For some reason it has been deleted; I will reopen.

ADD REPLYlink modified 2.7 years ago • written 2.7 years ago by Neilfws47k

Reopened; it closed again?

ADD REPLYlink written 2.7 years ago by Neilfws47k

I guess the post got deleted somehow, because I remembered that answer solved my problem, I didnt install EMBOSS in the first place.

ADD REPLYlink written 2.7 years ago by mossig890
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 581 users visited in the last hour