[Bioperl-l] Need help in needle parser

Chris Fields cjfields at uiuc.edu
Tue Jul 11 15:25:32 UTC 2006


There are a few odd things about the data you sent; the FASTA files aren't
FASTA format (they are raw) and the needle output doesn't have sequence
names.  You could try running these through needle with descriptors to see
if that helps, but.

 

it is very likely my option #2 (i.e. the parser doesn't recognize the
format).  There is a thread on the mail list about this issue:

 

http://thread.gmane.org/gmane.comp.lang.perl.bio.general/8926/focus=8935

 

Basically, it looks like the needle output has changed dramatically in
EMBOSS v3.  Jason's suggested options from the above thread (as well as
mine):

.

 

I think the "emboss" format changed in 3.0.0
solutions:
a) fix the AlignIO::emboss parser to handle both flavors (old and new)
b) have it output MSF format and use AlignIO::msf.

 

.

 

So, as a workaround, use MSF output.

 

I won't have time to look at this anytime soon as I'm busy at $job and
getting ready for a summer institute; I'll submit this as a bug to see if
someone else can tackle it before I get back in early August.

 

Chris

 

  _____  

From: Khoiwal Tara [mailto:khoiwal_tara at yahoo.co.in] 
Sent: Tuesday, July 11, 2006 8:26 AM
To: Chris Fields
Subject: Re: [Bioperl-l] Need help in needle parser

 

I am sending my testing data to you. I have two fasta files
"GenomicSeq.fasta" and "TranscriptSeq.fasta". I ran needle on these files as
follows:

 

$ needle GenomicSeq.fasta TranscriptSeq.fasta outfile.needle

 

So the out put of the needle will get stored in outfile.needle. I am
attaching the output file also. Please check it and tell me if it has any
problem.

Is my output file is correct?

 

Thanks and Regards,

Tara.

Chris Fields <cjfields at uiuc.edu> wrote:

perldoc Bio::AlignIO
perldoc Bio::AlignIO::needle

http://www.bioperl.org/wiki/FAQ
http://www.bioperl.org/wiki/HOWTO:Beginners
http://www.bioperl.org/wiki/Bptutorial.pl
http://www.catb.org/~esr/faqs/smart-questions.html

Google is your friend!

If it isn't entering the while loop, there are two possibilities:

1) Something is wrong with the file
2) The parser isn't reading the file correctly

In order to know which, we will need to see the alignment itself.

Chris

On Jul 11, 2006, at 7:19 AM, Khoiwal Tara wrote:

> Hi,
> I want to parse the output of needle.I tried but didn't able to 
> get expected output.
>
> My code is as follows:
>
> #!/usr/local/bin/perl
>
> use strict;
> use warnings;
> use Bio::AlignIO;
> my $needleReport = $ARGV[0];
>
> my $in = new Bio::AlignIO(-format => 'emboss',-file =>$needleReport);
>
> while(my $align = $in->next_aln()){
> print "Alignment Length:".$align->length()."\n";
> print "Percentage Identity:".$align->percentage_identity()."\n";
> print "Consensus string:".$align->consensus_string()."\n";
> print "Number of sequences:".$align->no_sequence()."\n";
> print "Number of residues:".$align->no_residues()."\n";
> }
>
> But it doesn't go inside the while loop.
> Pls help me.
> How to find the alignment position for the query sequence on the 
> target sequence from the needle output?
> Where can i find the good documentation on needle parser and its 
> usage?
> Good document on bioperl for beginners.
>
> Regards,
> Tara Khoiwal.
>
> 
> ---------------------------------
> Sneak preview the all-new Yahoo.com. It's not radically different. 
> Just radically better.
> _______________________________________________
> Bioperl-l mailing list
> Bioperl-l at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/bioperl-l

Christopher Fields
Postdoctoral Researcher
Lab of Dr. Robert Switzer
Dept of Biochemistry
University of Illinois Urbana-Champaign




 

  

  _____  

Do you Yahoo!?
Next-gen email? Have it all with the all-new
<http://us.rd.yahoo.com/evt=42241/*http:/advision.webevents.yahoo.com/handra
isers>  Yahoo! Mail Beta.




More information about the Bioperl-l mailing list