[Bioperl-l] get a full taxonomy path from Bio::Taxon

Mark A. Jensen maj at fortinbras.us
Sat Feb 6 13:52:31 UTC 2010


Try this, Ross:

use Bio::DB::SoapEUtilities;
my $fac = Bio::DB::SoapEUtilities->new();
my $links = $fac->elink( -db => 'taxonomy', -db_from => protein, -id => $accn )
                         ->run( -auto_adapt => 1 );

my $spcio = $fac->efetch( -db => 'taxonomy', -id => [ $links->id_map( $accn ) ])
                             ->run( -auto_adapt => 1);

my $species = $spcio->next_species;
my @fullpath = $species->classification;

Bio::DB::SoapEUtilities is in the bioperl-run trunk.

MAJ


----- Original Message ----- 
From: "Ross KK Leung" <ross at cuhk.edu.hk>
To: <bioperl-l at bioperl.org>
Sent: Saturday, February 06, 2010 6:09 AM
Subject: [Bioperl-l] get a full taxonomy path from Bio::Taxon


> In 2003, there's an old post asking about a way to get a full taxonomy.
>
>
>
> http://osdir.com/ml/lang.perl.bio.general/2003-08/msg00206.html
>
>
>
> Then Bio::Taxonomy is deprecated and now combination with Bio::Tree has to
> use in order to work out the story.
>
>
>
> In
>
>
>
> http://search.cpan.org/dist/bioperl/Bio/Taxon.pm
>
>
>
> it also gives an example by explicitly stating what to retrieve. However,
> what I need is to just provide a GI or accession number and to get a full
> taxonomy and I find there is no simple way (at least I don't know .) to do
> so. Would anybody advise?
>
>
>
> Thanks a lot,
>
> Ross
>
>
>
> _______________________________________________
> Bioperl-l mailing list
> Bioperl-l at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/bioperl-l
>
> 




More information about the Bioperl-l mailing list