[Bioperl-l] Fwd: SimpleAlign bug?

Chris Fields cjfields at uiuc.edu
Wed Apr 11 09:13:40 EDT 2007


I confirmed this; it is now fixed in CVS.  I have also added the  
option to prevent sorting if needed:

$aln2 = $aln->select_noncont(6,7,8,9,10,1,2,3,4,5);

sorts numerically by default.

$aln2 = $aln->select_noncont('nosort',6,7,8,9,10,1,2,3,4,5);

prevents sorting.  I have added a few tests to SimpleAlign.t for  
these.  It doesn't change the default behavior so shouldn't break  
anything.

chris

On Apr 11, 2007, at 7:33 AM, Chris Fields wrote:

> Don't know when this was added.  Maybe we should make the sorting
> optional?  In other words, pass an optional 'nosort' string as the
> first arg, defaulting to numerical sort.
>
> Either way the sort needs to be changed by the looks of it.  I'll
> verify the bug and commit today.
>
> chris
>
> On Apr 11, 2007, at 4:14 AM, Heikki Lehvaslaiho wrote:
>
>> What is going on here? Can anyone remember doing this?
>>
>> 	-Heikki
>>
>> Please can I ask what is the purpose of the line @pos = sort @pos; in
>> the select_noncont subroutine of SimpleAlign.pm.
>>
>>
>>
>> In previous versions this line was not present and I could use the
>> function to reorder the alignment e.g in an alignment with 5
>> sequences I
>> could reorder it to put the second sequence last using
>> $aln->select_noncont(1,3,4,5,2). The sort function stops this, but
>> even
>> if the idea is to sort numerically this dos not work since the sort
>> function as is will put 10 before 2, so that
>> ->select_noncont(1,2,3,4,5,6,7,8,9,10) would reorder the sequences in
>> the alignment to be 1, 10, 2, 3, 4,5, 6, 7, 8,9 .
>>
>>
>>
>> Many thanks
>>
>>
>>
>> Anthony
>> _______________________________________________
>> Bioperl-l mailing list
>> Bioperl-l at lists.open-bio.org
>> http://lists.open-bio.org/mailman/listinfo/bioperl-l
>
> Christopher Fields
> Postdoctoral Researcher
> Lab of Dr. Robert Switzer
> Dept of Biochemistry
> University of Illinois Urbana-Champaign
>
>
>
> _______________________________________________
> Bioperl-l mailing list
> Bioperl-l at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/bioperl-l

Christopher Fields
Postdoctoral Researcher
Lab of Dr. Robert Switzer
Dept of Biochemistry
University of Illinois Urbana-Champaign





More information about the Bioperl-l mailing list