[Biopython] sequence coordinate mapping

Peter biopython at maubp.freeserve.co.uk
Thu Jun 24 17:32:36 UTC 2010


On Wed, Jun 23, 2010 at 3:00 PM, Peter <biopython at maubp.freeserve.co.uk> wrote:
>>
>> In the worst case raising an exception will take a split second to fix,
>> while silent logic twists can in the best case take time and frustration to
>> find and fix (in the worst case it can lead to wrong results undetected).
>
> Agreed.
>
> I've made get_local_coord give an exception now for ambiguous
> mappings, and introduced get_local_coords (with a trailing s for
> plural) which gives a list of the local coordinates. That seems to
> cover the typical case nicely and makes dealing with the special
> case fairly easy.
>
> http://github.com/peterjc/biopython/tree/feature-coords

I've just added an __iter__ method which gives the parent coordinates
for each position in the feature (in the order of the local coordinates).
I expect that would be useful for something...

Peter



More information about the Biopython mailing list