[Bioperl-l] Bio::DB::GenBank get_seq_by_acc
Heikki Lehvaslaiho
heikki at ebi.ac.uk
Thu Jul 3 12:54:10 EDT 2003
Edith & James,
That was a sneaky bug. Thanks for the solution.
You really should not be forcds to add anything to accession number, so
I'll go and fix this in the module. Should be in the upcoming 1.2.2.
Cheers,
-Heikki
On Thu, 2003-07-03 at 12:18, Edith Schlagenhauf wrote:
> Hi James,
>
>
> On Thu, 3 Jul 2003, James Wasmuth wrote:
>
> > Hi all,
> >
> > I using the below script:
> >
> >
> > use Bio::DB::GenBank;
> > my @query_acc = qw/AF043104 CE24123 AF172351 AF435952/;
> > $embl=new Bio::DB::GenBank;
> > foreach $acc (@query_acc) {
> > print ":$acc:\n";
> > $seq = $embl->get_Seq_by_acc($acc);
> > ...
> > ...
> > }
>
> if you specify the database in query_acc array like:
>
> my @query_acc = qw/gb|AF043104 gb|AF172351 gb|AF435952/;
>
> # don't know what db for CE24123 entry is
>
> it works.
>
> I.e. the script below works in my case:
>
> use Bio::DB::GenBank;
>
> my @query_acc = qw/gb|AF043104 gb|AF172351 gb|AF435952/;
> $embl=new Bio::DB::GenBank;
> foreach $acc (@query_acc) {
> print STDOUT "\$acc is: $acc\n";
> $seqObj = $embl->get_Seq_by_acc($acc);
> $primary_id = $seqObj->primary_id();
> print "\$primary_id is: $primary_id\n";
> }
>
>
>
> Edith
>
>
> ******************************************
>
> Dr Edith Schlagenhauf
> Bioinformatics
> Institute of Plant Biology
> University of Zurich
> Zollikerstrasse 107
> CH-8008 Zurich
> SWITZERLAND
>
> e-mail: ediths AT botinst DOT unizh DOT ch
> Tel.: +41 1 634 82 56
> Fax : +41 1 634 82 04
>
> ******************************************
>
> _______________________________________________
> Bioperl-l mailing list
> Bioperl-l at portal.open-bio.org
> http://portal.open-bio.org/mailman/listinfo/bioperl-l
--
______ _/ _/_____________________________________________________
_/ _/ http://www.ebi.ac.uk/mutations/
_/ _/ _/ Heikki Lehvaslaiho heikki_at_ebi ac uk
_/_/_/_/_/ EMBL Outstation, European Bioinformatics Institute
_/ _/ _/ Wellcome Trust Genome Campus, Hinxton
_/ _/ _/ Cambs. CB10 1SD, United Kingdom
_/ Phone: +44 (0)1223 494 644 FAX: +44 (0)1223 494 468
___ _/_/_/_/_/________________________________________________________
More information about the Bioperl-l
mailing list