Bio::D...axonomy(3pm)

πŸ“¦
version 1.7.8 Β· 3 versions
, in debian bookworm, debian trixie, ubuntu jammy, ubuntu noble

πŸ’– Bio::DB::Taxonomy πŸ’–

okay bestie, so this one is from the User Contributed Perl Documentation set β€” it's Bio::DB::Taxonomy (the manpage header calls it Bio::D...axonomy(3pm), cute abbreviation era, we love her). Basically it's your front-row ticket to a taxonomy database. Let's get into it πŸ¦‹


✨ NAME ✨

Bio::DB::Taxonomy β€” access to a taxonomy database 🧬


🌸 SYNOPSIS 🌸

use Bio::DB::Taxonomy;
my $db = Bio::DB::Taxonomy->new(-source => 'entrez');
# use NCBI Entrez over HTTP
my $taxonid = $db->get_taxonid('Homo sapiens');

# get a taxon
my $taxon = $db->get_taxon(-taxonid => $taxonid);

πŸ’… DESCRIPTION πŸ’…

This is a front end module for access to a taxonomy database. That's it, that's the whole vibe β€” she's the door, the database is the party inside πŸŽ€


🫢 FEEDBACK 🫢

Mailing Lists

User feedback is an integral part of the evolution of this and other Bioperl modules. Send your comments and suggestions preferably to the Bioperl mailing list. Your participation is much appreciated. (fr fr, they mean it, they want to hear from you πŸ’Œ)

bioperl-l@bioperl.org                  - General discussion
http://bioperl.org/wiki/Mailing_lists  - About the mailing lists

Support

Please direct usage questions or support issues to the mailing list:

bioperl-l@bioperl.org

rather than to the module maintainer directly. Many experienced and reponsive experts will be able look at the problem and quickly address it. Please include a thorough description of the problem with code and data examples if at all possible. (ngl, the "reponsive" typo is canon, I'm keeping it, it's part of her now πŸ™ˆ)

Reporting Bugs

Report bugs to the Bioperl bug tracking system to help us keep track of the bugs and their resolution. Bug reports can be submitted via the web:

https://github.com/bioperl/bioperl-live/issues

πŸ‘‘ AUTHOR - Jason Stajich πŸ‘‘

Email jason-at-bioperl.org


🌈 CONTRIBUTORS 🌈

Sendu Bala: bix@sendu.me.uk


🧚 APPENDIX 🧚

The rest of the documentation details each of the object methods. Internal methods are usually preceded with a _ (iykyk, the underscore ones are the backstage crew πŸ’œ).

new

Title   : new
Usage   : my $obj = Bio::DB::Taxonomy->new(-source => 'entrez');
Function: Builds a new Bio::DB::Taxonomy object.
Returns : an instance of Bio::DB::Taxonomy
Args    : -source => which database source 'entrez' (NCBI taxonomy online),
                     'flatfile' (local NCBI taxonomy), 'greengenes' (local
                     GreenGenes taxonomy), 'silva' (local Silva taxonomy), or
                     'list' (Do-It-Yourself taxonomy)

get_num_taxa

Title   : get_num_taxa
Usage   : my $num = $db->get_num_taxa();
Function: Get the number of taxa stored in the database.
Returns : A number
Args    : None

get_taxon

Title   : get_taxon
Usage   : my $taxon = $db->get_taxon(-taxonid => $taxonid);
Function: Get a Bio::Taxon object from the database.
Returns : Bio::Taxon object
Args    : just a single value which is the database id, OR named args:
          -taxonid => taxonomy id (to query by taxonid)
            OR
          -name    => string (to query by a taxonomy name: common name,
                      scientific name, etc)

get_taxonids

Title   : get_taxonids
Usage   : my @taxonids = $db->get_taxonids('Homo sapiens');
Function: Searches for a taxonid (typically ncbi_taxon_id) based on a query
          string. Note that multiple taxonids can match to the same supplied
          name.
Returns : array of integer ids in list context, one of these in scalar context
Args    : string representing the taxon's name
heads up bestie: multiple taxonids can match to the same supplied name β€” don't assume you're getting one and only one 🌸

get_tree

Title   : get_tree
Usage   : my $tree = $db->get_tree(@species_names);
Function: Generate a tree comprised of the full lineages of all the supplied
          species names. The nodes for the requested species are given
          name('supplied') values corresponding to the supplied name, such that
          they can be identified if the real species name in the database
          (stored under node_name()) is different. The nodes are also given an
          arbitrary branch length of 1.
Returns : Bio::Tree::Tree
Args    : A list of species names (strings) to include in the tree.

ancestor

Title   : ancestor
Usage   : my $ancestor_taxon = $db->ancestor($taxon);
Function: Retrieve the full ancestor taxon of a supplied Taxon from the
          database.
Returns : Bio::Taxon
Args    : Bio::Taxon (that was retrieved from this database)

each_Descendent

Title   : each_Descendent
Usage   : my @taxa = $db->each_Descendent($taxon);
Function: Get all the descendents of the supplied Taxon (but not their
          descendents, ie. not a recursive fetchall).
Returns : Array of Bio::Taxon objects
Args    : Bio::Taxon (that was retrieved from this database)

get_all_Descendents

Title   : get_all_Descendents
Usage   : my @taxa = $db->get_all_Descendents($taxon);
Function: Like each_Descendent(), but do a recursive fetchall
Returns : Array of Bio::Taxon objects
Args    : Bio::Taxon (that was retrieved from this database)

_load_tax_module

Title   : _load_tax_module
Usage   : *INTERNAL Bio::DB::Taxonomy stuff*
Function: Loads up (like use) a module at run time on demand

_handle_internal_id

Title   : _handle_internal_id
Usage   : *INTERNAL Bio::DB::Taxonomy stuff*
Function: Add an internal ID to a taxon object, ensuring that the taxon gets
          the same internal ID, regardless of which database it is retrieved
          from.
Returns : The assigned internal ID
Args    : * A Bio::Taxon
          * An optional boolean to decide whether or not to try and do the job
            using scientific name & rank in addition to taxon ID. This is
            useful if your IDs are not comparable to that of other databases,
            e.g. if they are arbitrary, as in the case of Bio::DB::Taxonomy::list.
            CAVEAT: will handle ambiguous names within a database fine, but not
            across multiple databases.
CAVEAT alert 🚨 the optional boolean will handle ambiguous names within a database fine, but not across multiple databases. no cap, that's a real limitation, plan accordingly πŸ’€

and that's the whole page, bestie!! πŸŽ€ go forth and query some taxa πŸ¦‹

sign-off szn: this gem is perl v5.32.1, dated 2021-08-15 β€” that's the version and the date, and this whole thing is Bio::D...axonomy(3pm), mwah πŸ’‹ periodt ✨

πŸ“¦ where this page comes from