Bio::EnsEMBL::ExternalData::Glovar BaseComposition
SummaryIncluded librariesPackage variablesSynopsisDescriptionGeneral documentationMethods
Toolbar
WebCvsRaw content
Summary
Bio::EnsEMBL::ExternalData::Glovar::BaseComposition -
This object represents the base composition as provided by Glovar
Package variables
No package variables defined.
Included modules
Bio::EnsEMBL::SimpleFeature
Inherit
Bio::EnsEMBL::SimpleFeature
Synopsis
  my $base_comp = new Bio::EnsEMBL::ExternalData::Glovar::BaseComposition;
$base_comp->postition('1000');
$base_comp->genomic_base('A');
Description
This module holds data describing the base composition for each base in the
genome that has been covered by the Glovar project.
Methods
allelesDescriptionCode
endDescriptionCode
ethnicityDescriptionCode
genomic_baseDescriptionCode
newDescriptionCode
new_fastDescriptionCode
positionDescriptionCode
startDescriptionCode
Methods description
allelescode    nextTop
  Arg[1]      : (optional) hashref - alleles and their frequencies
Example : $base_comp->alleles({'A'=>3,'C'=>1,'G'=>0,'T'=>10});
Description : getter/setter for allele distribution
Return type : hashref - alleles and their freqencies
Exceptions : none
Caller : general
endcodeprevnextTop
  Arg[1]      : (optional) Int - genomic end position
Example : $base_comp->position('1000');
Description : getter/setter for genomic end position of BaseComposition
object. Identical to start position (since lenght of feature is
always 1)
Return type : Int - genomic end position
Exceptions : none
Caller : general
ethnicitycodeprevnextTop
  Arg[1]      : (optional) hashref - ethnicities and their read frequencies
Example : $base_comp->ethnicity({'Asian'=>2,'Caucasian'=>5});
Description : getter/setter for ethnicity of the reads the variation was
observed
Return type : hashref - ethnicities and their frequencies
Exceptions : none
Caller : general
genomic_basecodeprevnextTop
  Arg[1]      : (optional) String - genomic base
Example : $base_comp->genomic_base('A');
Description : getter/setter for genomic base of the variation (allele in
reference sequence)
Return type : String - genomic base
Exceptions : none
Caller : general
newcodeprevnextTop
  Arg[1]      : none
Example : see SYNOPSIS
Description : constructor method for a
Bio::EnsEMBL::ExternalData::Glovar::BaseComposition object
Return type : Bio::EnsEMBL::ExternalData::Glovar::BaseComposition
Exceptions : none
Caller : general
new_fastcodeprevnextTop
  Arg[1]      : hashref - initial object attributes
Example :
my $base_comp = new Bio::EnsEMBL::ExternalData::Glovar::BaseComposition({
'position' => 1,
'genomic_base' => 'A',
'alleles' => {
T => 20,
G => 10,
A => 0,
C => 2
},
'ethnicity' => {
Asian => 9,
Caucasian => 15,
},
'_gsf_strand' => 1,
});
Description : fast constructor method for a
Bio::EnsEMBL::ExternalData::Glovar::BaseComposition object.
Blesses the hashref supplied into your object
Return type : Bio::EnsEMBL::ExternalData::Glovar::BaseComposition
Exceptions : none
Caller : general
positioncodeprevnextTop
  Arg[1]      : (optional) Int - genomic position
Example : $base_comp->position('1000');
Description : getter/setter for genomic position of BaseComposition object
Return type : Int - genomic position
Exceptions : none
Caller : general
startcodeprevnextTop
  Arg[1]      : (optional) Int - genomic start position
Example : $base_comp->start('1000');
Description : getter/setter for genomic start position of BaseComposition
object
Return type : Int - genomic start position
Exceptions : none
Caller : general
Methods code
allelesdescriptionprevnextTop
sub alleles {
    my($self,$arg) = @_;
    $self->{'alleles'} = $arg if(defined $arg);
    return $self->{'alleles'};
}
enddescriptionprevnextTop
sub end {
    my ($self,$arg) = @_;
    $self->position($arg) if(defined $arg);
    return $self->position();
}
ethnicitydescriptionprevnextTop
sub ethnicity {
    my ($self, $arg) = @_;
    $self->{'ethnicity'} = $arg if (defined $arg);
    return $self->{'ethnicity'};
}

1;
}
genomic_basedescriptionprevnextTop
sub genomic_base {
    my ($self, $arg) = @_;
    $self->{'genomic_base'} = $arg if (defined $arg);
    return $self->{'genomic_base'};
}
newdescriptionprevnextTop
sub new {
    my $invocant = shift;
    my $class = ref($invocant) || $invocant;
    my $self = {
        'position'     => 0,
        'genomic_base' => 'undef',
        'alleles'      => {},
        'ethnicity'    => {},
        '_gsf_strand'  => 1,
        @_,
    };
    bless $self, $class;
    return $self;
}
new_fastdescriptionprevnextTop
sub new_fast {
    my $class = shift;
    my $hashref = shift;
    return bless $hashref, $class;
}
positiondescriptionprevnextTop
sub position {
    my ($self,$arg) = @_;
    if(defined $arg){
        $self->{'position'} = $arg;
    }
    return $self->{'position'};
}
startdescriptionprevnextTop
sub start {
    my ($self,$arg) = @_;
    $self->position($arg) if(defined $arg);
    return $self->position();
}
General documentation
LICENCETop
This code is distributed under an Apache style licence:
Please see /code_licence.html for details
AUTHORTop
Jody Clements <jc3@sanger.ac.uk>
Patrick Meidl <pm2@sanger.ac.uk>
CONTACTTop
Post questions to the EnsEMBL development list ensembl-dev@ebi.ac.uk