Ensembl Genomes API
Auxillary Perl API for Ensembl Genomes
 All Classes Functions
Public Member Functions | List of all members
Bio::EnsEMBL::TaxonomyNode Class Reference
Inheritance diagram for Bio::EnsEMBL::TaxonomyNode:

Public Member Functions

public new ()
 
public Int taxon_id ()
 
public Int parent_id ()
 
public Int root_id ()
 
public Hashref names ()
 
public name ()
 
public String rank ()
 
public Int num_descendants ()
 
public
Bio::EnsEMBL::DBSQL::TaxonomyNodeAdaptor 
dba ()
 
public Bio::EnsEMBL::TaxonomyNode root ()
 
public Bio::EnsEMBL::TaxonomyNode parent ()
 
public Arrayref children ()
 
public Int is_root ()
 
public Int is_leaf ()
 
public Int is_branch ()
 
public void add_all_descendants ()
 
public void add_child ()
 
public traverse_tree ()
 
public Int count_leaves ()
 
public Int distance_to_node ()
 
public Boolean has_ancestor ()
 
public to_string ()
 
public to_tree_string ()
 

Detailed Description

Synopsis

TODO

Description

An object representing a node of the NCBI taxonomy, (most often) created by
Bio::EnsEMBL::DBSQL::TaxonomyAdaptor.

Member Function Documentation

public void Bio::EnsEMBL::TaxonomyNode::add_all_descendants ( )
Description        : Uses database to fetch all descendants for this node from database and assemble them into a tree
Return type     : None
 
Code:
click to view
public void Bio::EnsEMBL::TaxonomyNode::add_child ( )
Description        : Add child node (if not already present)
Argument        : Arrayref of Bio::EnsEMBL::TaxonomyNode
Return type     : None
 
Code:
click to view
public Arrayref Bio::EnsEMBL::TaxonomyNode::children ( )
Description   : Getter/setter for arrayref of child nodes for this node (fetched lazily using adaptor)
Argument      : (optional) Arrayref of Bio::EnsEMBL::TaxonomyNode
Return type   : Arrayref of Bio::EnsEMBL::TaxonomyNode
 
Code:
click to view
public Int Bio::EnsEMBL::TaxonomyNode::count_leaves ( )
Description        : Counts all leaf or DBA nodes below this node
Argument        : (Optional) closure checking whether to count a node or not
Return type     : Int
 
Code:
click to view
public Bio::EnsEMBL::DBSQL::TaxonomyNodeAdaptor Bio::EnsEMBL::TaxonomyNode::dba ( )
Description : Getter/setter for core database adaptor for this node
Argument    : (optional) Bio::EnsEMBL::DBSQL::TaxonomyNodeAdaptor
Return type : Bio::EnsEMBL::DBSQL::TaxonomyNodeAdaptor
 
Code:
click to view
public Int Bio::EnsEMBL::TaxonomyNode::distance_to_node ( )
Description    : Calculate the distance between this and the supplied node in steps via the closest common ancestor
Argument        : Bio::EnsEMBL::TaxonomyNode
Return type     : Int
 
Code:
click to view
public Boolean Bio::EnsEMBL::TaxonomyNode::has_ancestor ( )
Description : Test if the ancestors of this node include the supplied node
Argument : Putative ancestor
Return: 1 if the supplied node is an ancestor of this node
 
Code:
click to view
public Int Bio::EnsEMBL::TaxonomyNode::is_branch ( )
Description     : Returns 1 if this is a branch node with more than one direct child
Return type     : Int
 
Code:
click to view
public Int Bio::EnsEMBL::TaxonomyNode::is_leaf ( )
Description     : Returns 1 if this is a leaf node with no children
Return type     : Int
 
Code:
click to view
public Int Bio::EnsEMBL::TaxonomyNode::is_root ( )
Description     : Returns 1 if this is a root node with no parents
Return type     : Int
 
Code:
click to view
public Bio::EnsEMBL::TaxonomyNode::name ( )

Undocumented method

Code:
click to view
public Hashref Bio::EnsEMBL::TaxonomyNode::names ( )
Description : Hashref of names for this node. Hash keys are the class of name, and values are arrays of names (as you can have more than one name for each class)
Return type : hashref
 
Code:
click to view
public Bio::EnsEMBL::TaxonomyNode::new ( )

Undocumented method

Code:
click to view
public Int Bio::EnsEMBL::TaxonomyNode::num_descendants ( )
Description : Total number of descendants in the tree
Return type : Int
 
Code:
click to view
public Bio::EnsEMBL::TaxonomyNode Bio::EnsEMBL::TaxonomyNode::parent ( )
Description   : Getter/setter for parent node for this node (fetched lazily using adaptor)
Argument      : (optional) Bio::EnsEMBL::TaxonomyNode
Return type   : Bio::EnsEMBL::TaxonomyNode
 
Code:
click to view
public Int Bio::EnsEMBL::TaxonomyNode::parent_id ( )
Taxon ID of the parent of this node
Return type : Int
 
Code:
click to view
public String Bio::EnsEMBL::TaxonomyNode::rank ( )
Description : Taxonomic rank
Return type : String
 
Code:
click to view
public Bio::EnsEMBL::TaxonomyNode Bio::EnsEMBL::TaxonomyNode::root ( )
Description   : Getter/setter for root node for this node (fetched lazily using adaptor)
Argument    : (optional) Bio::EnsEMBL::TaxonomyNode
Return type   : Bio::EnsEMBL::TaxonomyNode
 
Code:
click to view
public Int Bio::EnsEMBL::TaxonomyNode::root_id ( )
Description : Taxon ID of the root node for the taxonomy.
Return type : Int
 
Code:
click to view
public Int Bio::EnsEMBL::TaxonomyNode::taxon_id ( )
Description : Taxon ID of this node
Return type : Int
 
Code:
click to view
public Bio::EnsEMBL::TaxonomyNode::to_string ( )
Description : Return simple string representation of node
Argument : (Optional) name_class to display (default is 'scientific name')
 
Code:
click to view
public Bio::EnsEMBL::TaxonomyNode::to_tree_string ( )
Description: Render tree as a string
 
Code:
click to view
public Bio::EnsEMBL::TaxonomyNode::traverse_tree ( )
Description    : Walk the tree recursively, invoking the supplied subroutine on each node
Argument        : Subroutine reference, accepting current node and depth
 
Code:
click to view

The documentation for this class was generated from the following file: