[Bioperl-l] How to retrieve/parse RefSeq contig entries with Bio::DB::Query::GenBank?

Rumen Kostadinov rkostadi at gmail.com
Sun Dec 5 15:14:15 EST 2004


Hi,


Is there a way to retrieve and parse RefSeq contig entries with bioperl
using the Bio::DB::Query::GenBank?

e.g.
NT_079581

I get weird parsing when doing:

   my $query_string = param('query');
   my $query = Bio::DB::Query::GenBank->new(-db=>'nucleotide',
                                            -query=>$query_string);
   my $count = $query->count;
   my @ids   = $query->ids;

   # get a genbank database handle
   my $gb = new Bio::DB::GenBank;

   my $stream = $gb->get_Stream_by_query($query);
   while (my $seq = $stream->next_seq) {
       print "<tr><td>";
       print '<a href="map.pl?acc='.$seq->accession_number().';">';
       print $seq->accession_number(), '</a> ';
       print "<td>", $seq->desc(), br;
   }

Sincerely,
Rumen Kostadinov


More information about the Bioperl-l mailing list