[Bioperl-l] Bio::Variation::SeqDiff, Bio::Variation::VariantI
Heikki Lehvaslaiho
heikki@ebi.ac.uk
Wed, 29 May 2002 09:13:25 +0100
Eckhard,
Your idea looks good on paper. Go ahead and try it.
I have not touched these classes for a while. The current functionality was
enough for my needs. You are welcome to develop them further as long as you
do not changed existing methods too drasticly. ;-)
Yours,
-Heikki
Eckhard Lehmann wrote:
>
> Hi,
>
> as I know, I can create a Bio::Variation::DNAMutation and add alleles
> and other things to it, e.g. an "upStreamSeq" or a "dnStreamSeq".
> Then I can add the Bio::Variation::DNAMutation to a
> Bio::Variation::SeqDiff container and besides that I can set a sequence
> as dna_ori respectively dna_mut to the Bio::Variation::SeqDiff
> container.
>
> OK, that's fine ;-). But I wonder why I don't get the dna_mut sequence
> automatically when all DNAMutation objects and the dna_ori sequence are
> set correctly?
> Has there anything been done into this direction since bioperl-1.0? When
> not, I'd like to implement such a method:
>
> #------------------------------
> sub dna_mut {
> my ($self, $sq) = @_;
>
> return $self->{'dna_mut'} unless ($sq && $self->{'dna_mut'});
>
> if (!$sq && $self->{'dna_ori'}) {
> my $sq
> foreach ($self->each_Variant) {
> next unless $_->isMutation;
>
> my $sub_ori = $_->dnStreamSeq . $_->allele_ori . $_->upStreamSeq;
> my $sub_mut = $_->dnStreamSeq . $_->allele_mut . $_->upStreamSeq;
> ($sq = $self->{'dna_ori'}) =~ s/$sub_ori/$sub_mut/;
> }
> }
> $self->{'dna_mut'} = $sq;
> }
> #------------------------------
>
> or like this...
> It is not tested and I don't know whether it would work...
>
> Is it a good idea to change the dna_mut method that way in the public
> BioPerl?
>
> Thank you for suggestions and answers
>
> Eckhard
>
> _______________________________________________
> Bioperl-l mailing list
> Bioperl-l@bioperl.org
> http://bioperl.org/mailman/listinfo/bioperl-l
--
______ _/ _/_____________________________________________________
_/ _/ http://www.ebi.ac.uk/mutations/
_/ _/ _/ Heikki Lehvaslaiho heikki@ebi.ac.uk
_/_/_/_/_/ EMBL Outstation, European Bioinformatics Institute
_/ _/ _/ Wellcome Trust Genome Campus, Hinxton
_/ _/ _/ Cambs. CB10 1SD, United Kingdom
_/ Phone: +44 (0)1223 494 644 FAX: +44 (0)1223 494 468
___ _/_/_/_/_/________________________________________________________