[Bioperl-l] funny GI bug

Elia Stupka elia@fugu-sg.org
Mon, 5 Aug 2002 17:51:54 +0800 (SGT)


I am looking into this bug as we speak, but just to give a heads up to
others. Parsing genbank and printing out the primary_id (i.e. the GI
number) gives a Bio::Seq::RichSeq *object* instead of the actual GI
numbers on some records (e.g. genbank P34745  GI:1174398)

Code stripped to the bare minimum is just the standard:

use Bio::SeqIO;
my $file = shift(@ARGV);
my $seqio = Bio::SeqIO->new(-file=>"$file", -format=>"Genbank");
while (my $rec = $seqio->next_seq()) {
 my $gi = $rec->primary_id;
 print "$gi\n";
}

Looking into it now...

Elia

********************************
* http://www.fugu-sg.org/~elia *
* tel:    +65 6874 1467        *
* mobile: +65 9030 7613        *
* fax:    +65 6777 0402        *
********************************