I am trying to implement protein pairwise sequence alignment using “Global Alignment” algorithm by ‘Needleman -Wunsch’.
I am not clear about how to include ‘Blosum62 Matrix’ in my source code to do the scoring or to fill the two-dimensional matrix?
I have googled and found that most people suggested to use flat file which contains the standard ‘Blosum62 Matrix’. Does it mean that I need to read from this flat file and fill my coded “Blosum62 Martrix’ ?
Also, the other approach could be is to use some mathematical formula and include it in your programming logic to construct ‘Blosum62 Matrix’. But not very sure about this option.
Any ideas or insights are appreciated.
Thanks.
It would help to know what language you’re working in so we can help you with the correct terms, but what I did was use a map of maps (or dictionaries if you’re using Python).
Here’s an example of my code in Groovy, but it’s fairly portable to other languages:
Using this you can just call