Provided by: libbio-perl-perl_1.6.923-1_all
NAME
Bio::Phenotype::MeSH::Twig - Context for a MeSH term
SYNOPSIS
use Bio::Phenotype::MeSH::Twig # create a twig object my $twig = Bio::Phenotype::MeSH::Twig->new(); # the term has only one parent in any twig $twig->parent('Fats'); # a twig makeas sense only in the context of a term # which is a Bio::Phenotype::MeSH::Term object # a term can have many twigs i.e. it can appear in many places in # the hierarchy # $ term->add_twig($twig); # adding the twig into a term adds a link into into it $twig->term eq $term; # a twig can know about other terms under the parant node $twig->add_sister('Bread', 'Candy', 'Cereals'); print join ( ', ', $twig->each_sister()), "\n"; # a twig can know about other terms under this term $twig->add_child('Butter', 'Margarine'); print join ( ', ', $twig->each_child()), "\n";
DESCRIPTION
This class represents the immediate surrounding of a MeSH term. It keeps track on nodes names above the current node ('parent') other nodes at the same level ('sisters') and nodes under it ('children'). Note that these are name strings, not objects. Each twig can be associated with only one term, but term can have multiple twigs. (Twigs can be though to be roles for a term.)
SEE ALSO
Bio::Phenotype::MeSH::Term
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 lists Your participation is much appreciated. 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. Reporting Bugs report bugs to the Bioperl bug tracking system to help us keep track the bugs and their resolution. Bug reports can be submitted via the web: https://redmine.open-bio.org/projects/bioperl/
AUTHOR
Heikki Lehvaslaiho, heikki-at-bioperl-dot-org
APPENDIX
The rest of the documentation details each of the object methods. Internal methods are usually preceded with a _ parent Title : parent Usage : $obj->parent( "r1" ); or print $obj->parent(); Function: Set/get for the parent. Returns : A parent [scalar]. Args : A parent [scalar] (optional). term Title : term Usage : $obj->term( "r1" ); or print $obj->term(); Function: Set/get for the term. Returns : A term [scalar]. Args : A term [scalar] (optional). add_child Title : add_child Usage : $obj->add_child( @children ); or $obj->add_child( $child ); Function: Pushes one or more child term names [scalars, most likely Strings] into the list of children. Returns : Args : scalar(s). each_child Title : each_child() Usage : @gs = $obj->each_child(); Function: Returns a list of gene symbols [scalars, most likely Strings] associated with this phenotype. Returns : A list of scalars. Args : purge_children Usage : $obj->purge_child(); Function: Deletes the list of children associated with this term. Returns : A list of scalars. Args : add_sister Title : add_sister Usage : $obj->add_sister( @sisters ); or $obj->add_sister( $sister ); Function: Pushes one or more sister term names [scalars, most likely Strings] into the list of sisters. Returns : Args : scalar(s). each_sister Title : each_sister() Usage : @gs = $obj->each_sister(); Function: Returns a list of gene symbols [scalars, most likely Strings] associated with this phenotype. Returns : A list of scalars. Args : purge_sisters Usage : $obj->purge_sister(); Function: Deletes the list of sisters associated with this term. Returns : A list of scalars. Args :