Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

bio::phylonetwork::muvector(3pm) [debian man page]

Bio::PhyloNetwork::muVector(3pm)			User Contributed Perl Documentation			  Bio::PhyloNetwork::muVector(3pm)

NAME
Bio::PhyloNetwork::muVector - Module to compute with vectors of arbitrary dimension SYNOPSIS
use strict; use warnings; use Bio::PhyloNetwork::muVector; my $vec1=Bio::PhyloNetwork::muVector->new(4); my $vec2=Bio::PhyloNetwork::muVector->new([1,2,3,4]); my $vec3=Bio::PhyloNetwork::muVector->new([10,20,30,40]); my $vec4=$vec3-10*$vec2; if (($vec4 cmp $vec1) == 0) { print "$vec4 is zero "; } my $vec5=Bio::PhyloNetwork::muVector->new([8,2,2,4]); my $vec6=Bio::PhyloNetwork::muVector->new([1,2,3,4]); print "Test poset $vec5 > $vec6: ".$vec5->geq_poset($vec6)." "; print "Test lex $vec5 > $vec6: ".($vec5 cmp $vec6)." "; DESCRIPTION
This is a module to work with vectors. It creates vectors of arbitrary length, defines its basic arithmetic operations, its lexicographic ordering and the natural structure of poset. AUTHOR
Gabriel Cardona, gabriel(dot)cardona(at)uib(dot)es APPENDIX
The rest of the documentation details each of the object methods. new Title : new Usage : my $mu = new Bio::PhyloNetwork::muVector(); Function: Creates a new Bio::PhyloNetwork::muVector object Returns : Bio::PhyloNetwork::muVector Args : integer or (reference to) an array If given an integer as argument, returns a Bio::PhyloNetwork::muVector object with dimension the integer given and initialized to zero. If it is an anonimous array, then the vector is initialized with the values in the array and with the corresponding dimension. display Title : display Usage : my $str=$mu->display() Function: returns an string displaying its contents Returns : string Args : none This function is also overloaded to the "" operator. add Title : add Usage : $mu->add($mu2) Function: returns the sum of $mu and $mu2 Returns : Bio::PhyloNetwork::muVector Args : Bio::PhyloNetwork::muVector This function is also overloaded to the + operator. substract Title : substract Usage : $mu->substract($mu2) Function: returns the difference of $mu and $mu2 Returns : Bio::PhyloNetwork::muVector Args : Bio::PhyloNetwork::muVector This function is also overloaded to the - operator. scalarproduct Title : scalarproduct Usage : $mu->scalarproduct($ct) Function: returns the scalar product of $ct and $mu Returns : Bio::PhyloNetwork::muVector Args : scalar This function is also overloaded to the * operator. comparelex Title : comparelex Usage : $mu1->comparelex($mu2) Function: compares $mu and $mu2 w.r.t. the lexicographic ordering Returns : scalar (-1 if $mu1<$mu2, 0 if $mu1=$mu2, 1 if $mu1>$mu2) Args : Bio::PhyloNetwork::muVector This function is also overloaded to the <=> and cmp operator. geq_poset Title : geq_poset Usage : $mu1->geq_poset($mu2) Function: compares $mu and $mu2 w.r.t. the natural partial ordering Returns : boolean (1 if $mu >= $mu2, 0 otherwise) Args : Bio::PhyloNetwork::muVector is_positive Title : is_positive Usage : $mu->is_positive() Function: tests if all components of $mu are positive (or zero) Returns : boolean Args : none hamming Title : hamming Usage : $mu1->hamming($mu2) Function: returns the Hamming distance between $mu1 and $mu2 Returns : scalar Args : Bio::PhyloNetwork::muVector manhattan Title : manhattan Usage : $mu1->manhattan($mu2) Function: returns the Manhattan distance between $mu1 and $mu2 Returns : scalar Args : Bio::PhyloNetwork::muVector perl v5.14.2 2012-03-02 Bio::PhyloNetwork::muVector(3pm)

Check Out this Related Man Page

Bio::Annotation::Comment(3pm)				User Contributed Perl Documentation			     Bio::Annotation::Comment(3pm)

NAME
Bio::Annotation::Comment - A comment object, holding text SYNOPSIS
$comment = Bio::Annotation::Comment->new(); $comment->text("This is the text of this comment"); $annotation->add_Annotation('comment', $comment); DESCRIPTION
A holder for comments in annotations, just plain text. This is a very simple object, and justifiably so. AUTHOR - Ewan Birney Email birney@ebi.ac.uk APPENDIX
The rest of the documentation details each of the object methods. Internal methods are usually preceded with a _ new Title : new Usage : $comment = Bio::Annotation::Comment->new( '-text' => 'some text for this comment'); Function: This returns a new comment object, optionally with text filed Example : Returns : a Bio::Annotation::Comment object Args : a hash with -text optionally set AnnotationI implementing functions as_text Title : as_text Usage : Function: Example : Returns : Args : display_text 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 hash_tree Title : hash_tree Usage : Function: Example : Returns : Args : tagname 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 Bio::AnnotationCollectionI when adding this object. When obtaining an AnnotationI object from the collection, the collection will set the value to the tag under which it was stored unless the object has a tag stored already. Example : Returns : value of tagname (a scalar) Args : new value (a scalar, optional) Specific accessors for Comments text Title : text Usage : $value = $self->text($newval) Function: get/set for the text field. A comment object just holds a single string which is accessible through this method Example : Returns : value of text Args : newvalue (optional) value Title : value Usage : $value = $self->value($newval) Function: Alias of the 'text' method Example : Returns : value of text Args : newvalue (optional) type Title : type Usage : $value = $self->type($newval) Function: get/set for the comment type field. The comment type is normally found as a subfield within comment sections in some files, such as SwissProt Example : Returns : value of text Args : newvalue (optional) perl v5.14.2 2012-03-02 Bio::Annotation::Comment(3pm)
Man Page