.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.40) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "Bio::Annotation::OntologyTerm 3pm" .TH Bio::Annotation::OntologyTerm 3pm "2021-08-15" "perl v5.32.1" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Bio::Annotation::OntologyTerm \- An ontology term adapted to AnnotationI .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 3 \& use Bio::Annotation::OntologyTerm; \& use Bio::Annotation::Collection; \& use Bio::Ontology::Term; \& \& my $coll = Bio::Annotation::Collection\->new(); \& \& # this also implements a tag/value pair, where tag _and_ value are treated \& # as ontology terms \& my $annterm = Bio::Annotation::OntologyTerm\->new(\-label => \*(AqABC1\*(Aq, \& \-tagname => \*(AqGene Name\*(Aq); \& # ontology terms can be added directly \- they implicitly have a tag \& $coll\->add_Annotation($annterm); \& \& # implementation is by composition \- you can get/set the term object \& # e.g. \& my $term = $annterm\->term(); # term is\-a Bio::Ontology::TermI \& print "ontology term ",$term\->name()," (ID ",$term\->identifier(), \& "), ontology ",$term\->ontology()\->name(),"\en"; \& $term = Bio::Ontology::Term\->new(\-name => \*(AqABC2\*(Aq, \& \-ontology => \*(AqGene Name\*(Aq); \& $annterm\->term($term); .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" Ontology term annotation object .SH "FEEDBACK" .IX Header "FEEDBACK" .SS "Mailing Lists" .IX Subsection "Mailing Lists" User feedback is an integral part of the evolution of this and other Bioperl modules. Send your comments and suggestions preferably to one of the Bioperl mailing lists. Your participation is much appreciated. .PP .Vb 2 \& bioperl\-l@bioperl.org \- General discussion \& http://bioperl.org/wiki/Mailing_lists \- About the mailing lists .Ve .SS "Support" .IX Subsection "Support" Please direct usage questions or support issues to the mailing list: .PP \&\fIbioperl\-l@bioperl.org\fR .PP 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. .SS "Reporting Bugs" .IX Subsection "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: .PP .Vb 1 \& https://github.com/bioperl/bioperl\-live/issues .Ve .SH "AUTHOR \- Hilmar Lapp" .IX Header "AUTHOR - Hilmar Lapp" Email hlapp at gmx.net .SH "APPENDIX" .IX Header "APPENDIX" The rest of the documentation details each of the object methods. Internal methods are usually preceded with a _ .SS "new" .IX Subsection "new" .Vb 8 \& Title : new \& Usage : my $sv = Bio::Annotation::OntologyTerm\->new(); \& Function: Instantiate a new OntologyTerm object \& Returns : Bio::Annotation::OntologyTerm object \& Args : \-term => $term to initialize the term data field [optional] \& Most named arguments that Bio::Ontology::Term accepts will work \& here too. \-label is a synonym for \-name, \-tagname is a synonym for \& \-ontology. .Ve .SH "AnnotationI implementing functions" .IX Header "AnnotationI implementing functions" .SS "as_text" .IX Subsection "as_text" .Vb 6 \& Title : as_text \& Usage : my $text = $obj\->as_text \& Function: Returns a textual representation of the annotation that \& this object holds. Presently, it is tag name, name of the \& term, and the is_obsolete attribute concatenated togather \& with a delimiter (|). \& \& Returns : string \& Args : none .Ve .SS "display_text" .IX Subsection "display_text" .Vb 4 \& Title : display_text \& Usage : my $str = $ann\->display_text(); \& Function: returns a string. Unlike as_text(), this method returns a string \& formatted as would be expected for te specific implementation. \& \& One can pass a callback as an argument which allows custom text \& generation; the callback is passed the current instance and any text \& returned \& Example : \& Returns : a string \& Args : [optional] callback .Ve .SS "hash_tree" .IX Subsection "hash_tree" .Vb 6 \& Title : hash_tree \& Usage : my $hashtree = $value\->hash_tree \& Function: For supporting the AnnotationI interface just returns the value \& as a hashref with the key \*(Aqvalue\*(Aq pointing to the value \& Returns : hashrf \& Args : none .Ve .SS "tagname" .IX Subsection "tagname" .Vb 3 \& Title : tagname \& Usage : $obj\->tagname($newval) \& Function: Get/set the tagname for this annotation value. \& \& Setting this is optional. If set, it obviates the need to provide \& a tag to AnnotationCollection when adding this object. \& \& This is aliased to ontology() here. \& Example : \& Returns : value of tagname (a scalar) \& Args : new value (a scalar, optional) .Ve .SH "Methods for Bio::Ontology::TermI compliance" .IX Header "Methods for Bio::Ontology::TermI compliance" .SS "term" .IX Subsection "term" .Vb 3 \& Title : term \& Usage : $obj\->term($newval) \& Function: Get/set the Bio::Ontology::TermI implementing object. \& \& We implement TermI by composition, and this method sets/gets the \& object we delegate to. \& Example : \& Returns : value of term (a Bio::Ontology::TermI compliant object) \& Args : new value (a Bio::Ontology::TermI compliant object, optional) .Ve .SS "identifier" .IX Subsection "identifier" .Vb 7 \& Title : identifier \& Usage : $term\->identifier( "0003947" ); \& or \& print $term\->identifier(); \& Function: Set/get for the identifier of this Term. \& Returns : The identifier [scalar]. \& Args : The identifier [scalar] (optional). .Ve .SS "name" .IX Subsection "name" .Vb 7 \& Title : name \& Usage : $term\->name( "N\-acetylgalactosaminyltransferase" ); \& or \& print $term\->name(); \& Function: Set/get for the name of this Term. \& Returns : The name [scalar]. \& Args : The name [scalar] (optional). .Ve .SS "definition" .IX Subsection "definition" .Vb 7 \& Title : definition \& Usage : $term\->definition( "Catalysis of ..." ); \& or \& print $term\->definition(); \& Function: Set/get for the definition of this Term. \& Returns : The definition [scalar]. \& Args : The definition [scalar] (optional). .Ve .SS "ontology" .IX Subsection "ontology" .Vb 9 \& Title : ontology \& Usage : $term\->ontology( $top ); \& or \& $top = $term\->ontology(); \& Function: Set/get for a relationship between this Term and \& another Term (e.g. the top level of the ontology). \& Returns : The ontology of this Term [TermI]. \& Args : The ontology of this Term [TermI or scalar \-\- which \& becomes the name of the category term] (optional). .Ve .SS "is_obsolete" .IX Subsection "is_obsolete" .Vb 7 \& Title : is_obsolete \& Usage : $term\->is_obsolete( 1 ); \& or \& if ( $term\->is_obsolete() ) \& Function: Set/get for the obsoleteness of this Term. \& Returns : the obsoleteness [0 or 1]. \& Args : the obsoleteness [0 or 1] (optional). .Ve .SS "comment" .IX Subsection "comment" .Vb 7 \& Title : comment \& Usage : $term\->comment( "Consider the term ..." ); \& or \& print $term\->comment(); \& Function: Set/get for an arbitrary comment about this Term. \& Returns : A comment. \& Args : A comment (optional). .Ve .SS "get_synonyms" .IX Subsection "get_synonyms" .Vb 5 \& Title : get_synonyms() \& Usage : @aliases = $term\->get_synonyms(); \& Function: Returns a list of aliases of this Term. \& Returns : A list of aliases [array of [scalar]]. \& Args : .Ve .SS "add_synonym" .IX Subsection "add_synonym" .Vb 7 \& Title : add_synonym \& Usage : $term\->add_synonym( @asynonyms ); \& or \& $term\->add_synonym( $synonym ); \& Function: Pushes one or more synonyms into the list of synonyms. \& Returns : \& Args : One synonym [scalar] or a list of synonyms [array of [scalar]]. .Ve .SS "remove_synonyms" .IX Subsection "remove_synonyms" .Vb 5 \& Title : remove_synonyms() \& Usage : $term\->remove_synonyms(); \& Function: Deletes (and returns) the synonyms of this Term. \& Returns : A list of synonyms [array of [scalar]]. \& Args : .Ve .SS "get_dblinks" .IX Subsection "get_dblinks" .Vb 7 \& Title : get_dblinks() \& Usage : @ds = $term\->get_dblinks(); \& Function: Returns a list of each dblinks of this GO term. \& Returns : A list of dblinks [array of [scalars]]. \& Args : \& Note : this is deprecated in favor of get_dbxrefs(), which works with strings \& or L instances .Ve .SS "get_dbxrefs" .IX Subsection "get_dbxrefs" .Vb 5 \& Title : get_dbxrefs() \& Usage : @ds = $term\->get_dbxrefs(); \& Function: Returns a list of each dblinks of this GO term. \& Returns : A list of dblinks [array of [scalars] or Bio::Annotation::DBLink instances]. \& Args : .Ve .SS "add_dblink" .IX Subsection "add_dblink" .Vb 11 \& Title : add_dblink \& Usage : $term\->add_dblink( @dbls ); \& or \& $term\->add_dblink( $dbl ); \& Function: Pushes one or more dblinks \& into the list of dblinks. \& Returns : \& Args : One dblink [scalar] or a list of \& dblinks [array of [scalars]]. \& Note : this is deprecated in favor of add_dbxref(), which works with strings \& or L instances .Ve .SS "add_dbxref" .IX Subsection "add_dbxref" .Vb 8 \& Title : add_dbxref \& Usage : $term\->add_dbxref( @dbls ); \& or \& $term\->add_dbxref( $dbl ); \& Function: Pushes one or more dblinks \& into the list of dblinks. \& Returns : \& Args : .Ve .SS "remove_dblinks" .IX Subsection "remove_dblinks" .Vb 7 \& Title : remove_dblinks() \& Usage : $term\->remove_dblinks(); \& Function: Deletes (and returns) the definition references of this GO term. \& Returns : A list of definition references [array of [scalars]]. \& Args : \& Note : this is deprecated in favor of remove_dbxrefs(), which works with strings \& or L instances .Ve .SS "remove_dbxrefs" .IX Subsection "remove_dbxrefs" .Vb 5 \& Title : remove_dbxrefs() \& Usage : $term\->remove_dbxrefs(); \& Function: Deletes (and returns) the definition references of this GO term. \& Returns : A list of definition references [array of [scalars]]. \& Args : .Ve .SS "get_secondary_ids" .IX Subsection "get_secondary_ids" .Vb 3 \& Title : get_secondary_ids \& Usage : @ids = $term\->get_secondary_ids(); \& Function: Returns a list of secondary identifiers of this Term. \& \& Secondary identifiers mostly originate from merging terms, \& or possibly also from splitting terms. \& \& Returns : A list of secondary identifiers [array of [scalar]] \& Args : .Ve .SS "add_secondary_id" .IX Subsection "add_secondary_id" .Vb 7 \& Title : add_secondary_id \& Usage : $term\->add_secondary_id( @ids ); \& or \& $term\->add_secondary_id( $id ); \& Function: Adds one or more secondary identifiers to this term. \& Returns : \& Args : One or more secondary identifiers [scalars] .Ve .SS "remove_secondary_ids" .IX Subsection "remove_secondary_ids" .Vb 5 \& Title : remove_secondary_ids \& Usage : $term\->remove_secondary_ids(); \& Function: Deletes (and returns) the secondary identifiers of this Term. \& Returns : The previous list of secondary identifiers [array of [scalars]] \& Args : .Ve