Bio::T...leNode(3pm)
π Bio::Tree::AnnotatableNode π
okay bestie, welcome to the Bio::Tree::AnnotatableNode page β it's a chunk of User Contributed Perl Documentation and honestly? it's giving tree-node-with-extras. it's the one where your node can also hold vibes (by which i mean annotations). let's go π¦
β¨ NAME β¨
Bio::Tree::AnnotatableNode β a Tree Node with support for annotation π
πΈ SYNOPSIS πΈ
use Bio::Tree::AnnotatableNode;
my $nodeA = Bio::Tree::AnnotatableNode->new();
my $nodeL = Bio::Tree::AnnotatableNode->new();
my $nodeR = Bio::Tree::AnnotatableNode->new();
my $node = Bio::Tree::AnnotatableNode->new();
$node->add_Descendents($nodeL);
$node->add_Descendents($nodeR);
print "node is not a leaf \n" if( $node->is_leaf);
# $node is-a Bio::AnnotatableI, hence:
my $ann_coll = $node->annotation();
# $ann_coll is-a Bio::AnnotationCollectionI, hence:
my @all_anns = $ann_coll->get_Annotations();
# do something with the annotation objects
no cap, that last part is the whole point β you grab the collection, you grab the annotations, you do whatever you want with the annotation objects β¨
π DESCRIPTION π
it makes a Tree Node with Annotations, and it's suitable for building a Tree. if you want the full list of functionality, go look at Bio::Tree::Node β that's where the rest of the moves live π«Ά
π«Ά FEEDBACK π«Ά
Mailing Lists π
user feedback is, like, an integral part of the evolution of this and other Bioperl modules. so send your comments and suggestions β preferably to the Bioperl mailing list. your participation is much appreciated, fr fr π₯Ή
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. why? because many experienced and reponsive experts will be able look at the problem and quickly address it π and please include a thorough description of the problem with code and data examples if at all possible β the more detail the better, bestie.
Reporting Bugs π
report bugs to the Bioperl bug tracking system so we can keep track of the bugs and their resolution. bug reports can be submitted via the web:
https://github.com/bioperl/bioperl-live/issues
π AUTHOR - Mira Han π
email mirhan@indiana.edu
π§ APPENDIX π§
the rest of the documentation details each of the object methods. internal methods are usually preceded with a _ (iykyk) π
new β
- Title β
new - Usage β
my $obj = Bio::Tree::AnnotatableNode->new(); - Function β Builds a new
Bio::Tree::AnnotatableNodeobject - Returns β
Bio::Tree::AnnotatableNode - Args β
-tostring=> code reference to the tostring callback function (optional)
Methods for implementing Bio::AnnotatableI π
annotation π
- Title β
annotation - Usage β
$ann = $node->annotationor$node->annotation($ann) - Function β Gets or sets the annotation
- Returns β
Bio::AnnotationCollectionIobject - Args β None or
Bio::AnnotationCollectionIobject
see Bio::AnnotationCollectionI and Bio::Annotation::Collection for more information π
Methods for implementing tag access through Annotation::SimpleValue π
add_tag_value π·οΈ
- Title β
add_tag_value - Usage β
$node->add_tag_value($tag,$value) - Function β Adds a tag value to a node
- Returns β number of values stored for this tag
- Args β
$tagβ tag name;$valueβ value to store for the tag
remove_tag βοΈ
- Title β
remove_tag - Usage β
$node->remove_tag($tag) - Function β Remove the tag and all values for this tag
- Returns β boolean representing success (0 if tag does not exist)
- Args β
$tagβ tagname to remove
remove_all_tags π₯
- Title β
remove_all_tags - Usage β
$node->remove_all_tags() - Function β Removes all tags
- Returns β None
- Args β None
get_all_tags π
- Title β
get_all_tags - Usage β
my @tags = $node->get_all_tags() - Function β Gets all the tag names for this Node
- Returns β Array of tagnames
- Args β None
get_tag_values π
- Title β
get_tag_values - Usage β
my @values = $node->get_tag_value($tag) - Function β Gets the values for given tag (
$tag) - Returns β Array of values or empty list if tag does not exist
- Args β
$tagβ tag name
has_tag β
- Title β
has_tag - Usage β
$node->has_tag($tag) - Function β Boolean test if tag exists in the Node
- Returns β Boolean
- Args β
$tagβ tagname
Methods for implementing to_string πͺ
to_string_callback π―
- Title β
to_string_callback - Usage β
$node->to_string_callback(\&func) - Function β get/set callback for
to_string - Returns β code reference for the
to_stringcallback function - Args β
\&funcβ code reference to be set as the callback function
Methods for accessing Bio::Seq π§¬
sequence πΈ
- Title β
sequence - Usage β
$ann = $node->sequenceor$node->sequence($seq) - Function β Gets or sets the sequence
- Returns β array reference of
Bio::SeqIobjects - Args β None or
Bio::SeqIobject
see Bio::SeqI and Bio::Seq for more information π
has_sequence π
- Title β
has_sequence - Usage β
if( $node->has_sequence) { # do something } - Function β tells if node has sequence attached
- Returns β Boolean for whether or not node has
Bio::SeqIattached. - Args β None
and that's the whole page, bestie β you ate it UP π β¨
this was served to you straight outta User Contributed Perl Documentation, perl v5.32.1, dated 2021-08-15. go build a tree that knows things, queen ππ¦π
π¦ where this page comes from
- debian bookworm: libbio-perl-perl 1.7.8-1 Β· Perl
- debian trixie: libbio-perl-perl 1.7.8-1 Β· Perl
- ubuntu jammy: libbio-perl-perl 1.7.8-1 Β· Perl
- ubuntu noble: libbio-perl-perl 1.7.8-1 Β· Perl
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms