BioPerl
view release on metacpan or search on metacpan
Bio/Cluster/SequenceFamily.pm view on Meta::CPAN
bioperl-l@bioperl.org - General discussion
http://bioperl.org/wiki/Mailing_lists - About the mailing lists
=head2 Support
Please direct usage questions or support issues to the mailing list:
I<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.
=head2 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://github.com/bioperl/bioperl-live/issues
=head1 AUTHOR - Shawn Hoon
Email shawnh@fugu-sg.org
=head1 APPENDIX
The rest of the documentation details each of the object
methods. Internal methods are usually preceded with a "_".
=cut
# Let the code begin...
package Bio::Cluster::SequenceFamily;
use strict;
use warnings;
use base qw(Bio::Root::Root Bio::Cluster::FamilyI);
=head2 new
Title : new
Usage : my $family = Bio::Cluster::SequenceFamily->new(
-family_id=>"Family_1",
-description=>"Family Description Here",
-annotation_score=>"100",
-members=>\@mem);
Function: Constructor for SequenceFamily object
Returns : Bio::Cluster::SequenceFamily object
See L<Bio::Cluster::SequenceFamily>.
=cut
sub new {
my ($class,@args) = @_;
my $self = $class->SUPER::new(@args);
my ($id,$description,$version,$annot_score,
$family_score,$members) = $self->_rearrange([qw(FAMILY_ID DESCRIPTION VERSION
ANNOTATION_SCORE
FAMILY_SCORE MEMBERS)],@args);
$self->{'_members'} = [];
$id && $self->family_id($id);
$description && $self->description($description);
$version && $self->version($version);
$annot_score && $self->annotation_score($annot_score);
$family_score && $self->family_score($family_score);
$members && $self->add_members($members);
return $self;
}
=head2 version
Title : version
Usage : $family->version("1.0");
Function: get/set for version
Returns : a string version of the family generated.
=cut
sub version{
my ($self,$value) = @_;
if($value){
$self->{'_version'} =$value;
}
return $self->{'_version'};
}
=head2 annotation_score
Title : annotation_score
Usage : $family->annotation_score(100);
Function: get/set for annotation_score which
represent the confidence in which the
consensus description has been assigned
to the family.
Returns : Bio::SimpleAlign
See L<Bio::SimpleAlign>
=cut
sub annotation_score{
my ($self,$score) = @_;
if($score){
$self->{'_annotation_score'} = $score;
}
return $self->{'_annotation_score'};
}
=head2 alignment
Title : alignment
Usage : $family->alignment($align);
Function: get/set for an alignment object representing
the multiple alignment of the members of the family.
Returns : Bio::SimpleAlign
See L<Bio::SimpleAlign>
=cut
sub alignment {
my ($self,$align) = @_;
if($align){
( run in 0.793 second using v1.01-cache-2.11-cpan-39bf76dae61 )