This is a test version of Biostars. For the public version, visit https://www.biostars.org.
A Map(?) Of Sequence Alignment

Hi,

I'm finding it hard to express my problem in very few words (so I may have missed the solution to my problem while googling for it). I need to align two sequences, but as an output I want to know which base of my sequence translates to which base of the reference sequence, so I would get a sort of a map. I don't need to see two lines of letters under each other.

To explain, I want to use this map as a part of my code, to bridge some information about the sequence at the input side and some at the reference side (SNP's). I have a hunch this kind of mapping is used somewhere along while doing a classical alignment, but I wouldn't mind your advice before I start digging in the code of aligners.

Nevertheless I still need to keep this alignment 'classical' in the sense to know where the gaps and variations are.

Thanks for any hints/suggestions.

sequence alignment aligner

1 answer

You are just asking for a mapping between coordinates in the two strings? eg for

AACGT

AC_TT

is your map (in the mathematical sense)

1->1

2->2

3->?

4->3

5->4

where left hand number is coordinate in AACGT and right-hand is coordinate in ACTT? How do you want to define the value which it assigns to 3? Sounds like you could write something very easily which takes output from a standard aligner?

Yes this is exactly how I imagined it. Assigning the left 3 something like 2.1 on the right. An yes, I too believe it shouldn't be complicated to write something like that, but it seems to me like doing unnecessary backtracking (since I assume a map like this would be built in a program during the process of alignment, my idea was to exploit this map - if there is one like that and I could get access to it through the code).

Log in to answer this question.