SlideShare a Scribd company logo
1 of 20
Needleman-Wunsch
Algorithm 1
11-Dec-2015
Presented By:
• Proshanta Kumar Shil
ID:141-15-3140
Section:B
Department of CSE
Daffodil International University
11-Dec-2015
2
What is Needleman-Wunsch algorithm?
The Needleman–Wunsch algorithm is an algorithm used
in bioinformatics to align protein or nucleotide sequences.
• It was one of the first applications of dynamic programming to compare
biological sequences.
• The algorithm was developed by Saul B. Needleman and Christian D.
Wunsch and published in 1970.
3
11-Dec-2015
Alignment methods
• Global and local sequence alignment methods
• Global : Needleman-Wunch
• Local : Smith-Waterman
• Database Search
• BLAST
• FASTA
4
11-Dec-2015
Goals of sequence databases
• To know about a newly sequenced database.
• To find the similarity of a unique sequence to another gene that
has a known function.
• To find the similarity of a new protein in a lower organism to a
protein from another species.
5
11-Dec-2015
Alignment Algorithms
• Global : Needleman-Wunch
• Local : Smith-Watermann
•  These two dynamic programming alignment algorithm are
guaranteed to give OPTIMAL alignments
•  But O(m*n) quadratic
6
11-Dec-2015
Needleman-Wunsch Method
• For example, the two hypothetical sequences
• abcdefghajklm
• abbdhijk
• could be aligned like this
• abcdefghajklm
• || | | ||
• abbd...hijk
• As shown, there are 6 matches,
• 2 mismatches, and one gap of length 3.
7
11-Dec-2015
Needleman-Wunsch Method
• The alignment is scored according to a payoff matrix
• $payoff = { match => $match,
• mismatch => $mismatch,
• gap_open => $gap_open,
• gap_extend => $gap_extend };
• For correct operation, match must be positive,
• and the other entries must be negative.
8
11-Dec-2015
Needleman-Wunsch Method
• Given the payoff matrix
• $payoff = { match => 4,
• mismatch => -3,
• gap_open => -2,
• gap_extend => -1 };
9
11-Dec-2015
Needleman-Wunsch Method
• The sequences
• abcdefghajklm
• abbdhijk
• are aligned and scored like this
• a b c d e f g h a j k l m
• | | | | | |
• a b b d . . . h i j k
• match 4 4 4 4 4 4
• mismatch -3 -3
• gap_open -2
• gap_extend -1-1-1
• for a total score of 24-6-2-3 = 13.
10
11-Dec-2015
Steps:
• 1. Initialization
• 2 Matrix fill or scoring
• 3. Traceback and alignment
11
11-Dec-2015
Lets see an example…
12
11-Dec-2015
Fill in the Table 13
11-Dec-2015
A G C
A
A
C
C
Two sequences will be aligned.
AGC (sequence #1)
AACC (sequence #2)
A simple scoring scheme will be used
Initialization step:
Create Matrix with M + 1
columns
and N + 1 rows.
For match=+1; Mismatch=-1;
Gap=-2
14
11-Dec-2015
A G C
0 -2 -4 -6
A -2
A -4
C -6
C -8
15
11-Dec-2015
Fill in the Table
A G C
0 -2 -4 -6
A -2 1
A -4
C -6
C -8
Matrix fill step: Each position Mi,j is defined to be the
MAXIMUM score at position i,j
Mi,j = MAXIMUM [
Mi-1, j-1 + si,,j (match or mismatch in the diagonal)
Mi, j-1 + w (gap in sequence #1)
Mi-1, j + w (gap in sequence #2)]
Continuing
the procedure 16
11-Dec-2015
A G C
0 -2 -4 -6
A -2 1 -1 -3
A -4 -1 0 -2
C -6 -3 -2 -1
C -8 -5 -4 -1
Traceback step:
Position at current cell
and look at direct
predecessors
17
11-Dec-2015
A G C
0 -2 -4 -6
A -2 1 -1 -3
A -4 -1 0 -2
C -6 -3 -2 -1
C -8 -5 -4 -1
Traceback step:
Position at current cell and
look at direct predecessors
18
11-Dec-2015
A G C
0 -2 -4 -6
A -2 1 -1 -3
A -4 -1 0 -2
C -6 -3 -2 -1
C -8 -5 -4 -1
AG-C
AAAC
-AGC
AAAC
A-GC
AAAC
Summary
• The algorithm essentially divides a large problem into a series of
smaller problems and uses the solutions to the smaller problems to
reconstruct a solution to the larger problem.
• It is also sometimes referred to as the optimal matching algorithm
and the global alignment technique.
• The Needleman–Wunsch algorithm is still widely used for optimal
global alignment, particularly when the quality of the global
alignment is of the utmost importance.
11-Dec-2015
19
Any Question?
Thanks to All
20

More Related Content

What's hot (20)

Dot matrix
Dot matrixDot matrix
Dot matrix
 
Clustal W - Multiple Sequence alignment
Clustal W - Multiple Sequence alignment   Clustal W - Multiple Sequence alignment
Clustal W - Multiple Sequence alignment
 
Global and local alignment (bioinformatics)
Global and local alignment (bioinformatics)Global and local alignment (bioinformatics)
Global and local alignment (bioinformatics)
 
Clustal
ClustalClustal
Clustal
 
Primary, secondary, tertiary biological database
Primary, secondary, tertiary biological databasePrimary, secondary, tertiary biological database
Primary, secondary, tertiary biological database
 
Sequence alignment
Sequence alignmentSequence alignment
Sequence alignment
 
Protein 3 d structure prediction
Protein 3 d structure predictionProtein 3 d structure prediction
Protein 3 d structure prediction
 
Comparative genomics
Comparative genomicsComparative genomics
Comparative genomics
 
smith - waterman algorithm.pptx
smith - waterman algorithm.pptxsmith - waterman algorithm.pptx
smith - waterman algorithm.pptx
 
BLAST
BLASTBLAST
BLAST
 
Protein data bank
Protein data bankProtein data bank
Protein data bank
 
Multiple sequence alignment
Multiple sequence alignmentMultiple sequence alignment
Multiple sequence alignment
 
Sequence alignment global vs. local
Sequence alignment  global vs. localSequence alignment  global vs. local
Sequence alignment global vs. local
 
methods for protein structure prediction
methods for protein structure predictionmethods for protein structure prediction
methods for protein structure prediction
 
Ddbj
DdbjDdbj
Ddbj
 
MULTIPLE SEQUENCE ALIGNMENT
MULTIPLE  SEQUENCE  ALIGNMENTMULTIPLE  SEQUENCE  ALIGNMENT
MULTIPLE SEQUENCE ALIGNMENT
 
UniProt
UniProtUniProt
UniProt
 
PIR- Protein Information Resource
PIR- Protein Information ResourcePIR- Protein Information Resource
PIR- Protein Information Resource
 
dot plot analysis
dot plot analysisdot plot analysis
dot plot analysis
 
blast bioinformatics
blast bioinformaticsblast bioinformatics
blast bioinformatics
 

Recently uploaded

scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...HenryBriggs2
 
8086 Microprocessor Architecture: 16-bit microprocessor
8086 Microprocessor Architecture: 16-bit microprocessor8086 Microprocessor Architecture: 16-bit microprocessor
8086 Microprocessor Architecture: 16-bit microprocessorAshwiniTodkar4
 
Max. shear stress theory-Maximum Shear Stress Theory ​ Maximum Distortional ...
Max. shear stress theory-Maximum Shear Stress Theory ​  Maximum Distortional ...Max. shear stress theory-Maximum Shear Stress Theory ​  Maximum Distortional ...
Max. shear stress theory-Maximum Shear Stress Theory ​ Maximum Distortional ...ronahami
 
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills KuwaitKuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwaitjaanualu31
 
PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiessarkmank1
 
Path loss model, OKUMURA Model, Hata Model
Path loss model, OKUMURA Model, Hata ModelPath loss model, OKUMURA Model, Hata Model
Path loss model, OKUMURA Model, Hata ModelDrAjayKumarYadav4
 
Convergence of Robotics and Gen AI offers excellent opportunities for Entrepr...
Convergence of Robotics and Gen AI offers excellent opportunities for Entrepr...Convergence of Robotics and Gen AI offers excellent opportunities for Entrepr...
Convergence of Robotics and Gen AI offers excellent opportunities for Entrepr...ssuserdfc773
 
Electromagnetic relays used for power system .pptx
Electromagnetic relays used for power system .pptxElectromagnetic relays used for power system .pptx
Electromagnetic relays used for power system .pptxNANDHAKUMARA10
 
Digital Communication Essentials: DPCM, DM, and ADM .pptx
Digital Communication Essentials: DPCM, DM, and ADM .pptxDigital Communication Essentials: DPCM, DM, and ADM .pptx
Digital Communication Essentials: DPCM, DM, and ADM .pptxpritamlangde
 
Augmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptxAugmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptxMustafa Ahmed
 
👉 Yavatmal Call Girls Service Just Call 🍑👄6378878445 🍑👄 Top Class Call Girl S...
👉 Yavatmal Call Girls Service Just Call 🍑👄6378878445 🍑👄 Top Class Call Girl S...👉 Yavatmal Call Girls Service Just Call 🍑👄6378878445 🍑👄 Top Class Call Girl S...
👉 Yavatmal Call Girls Service Just Call 🍑👄6378878445 🍑👄 Top Class Call Girl S...manju garg
 
School management system project Report.pdf
School management system project Report.pdfSchool management system project Report.pdf
School management system project Report.pdfKamal Acharya
 
Query optimization and processing for advanced database systems
Query optimization and processing for advanced database systemsQuery optimization and processing for advanced database systems
Query optimization and processing for advanced database systemsmeharikiros2
 
fitting shop and tools used in fitting shop .ppt
fitting shop and tools used in fitting shop .pptfitting shop and tools used in fitting shop .ppt
fitting shop and tools used in fitting shop .pptAfnanAhmad53
 
Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)Ramkumar k
 
8th International Conference on Soft Computing, Mathematics and Control (SMC ...
8th International Conference on Soft Computing, Mathematics and Control (SMC ...8th International Conference on Soft Computing, Mathematics and Control (SMC ...
8th International Conference on Soft Computing, Mathematics and Control (SMC ...josephjonse
 
Hostel management system project report..pdf
Hostel management system project report..pdfHostel management system project report..pdf
Hostel management system project report..pdfKamal Acharya
 
Ground Improvement Technique: Earth Reinforcement
Ground Improvement Technique: Earth ReinforcementGround Improvement Technique: Earth Reinforcement
Ground Improvement Technique: Earth ReinforcementDr. Deepak Mudgal
 
Basic Electronics for diploma students as per technical education Kerala Syll...
Basic Electronics for diploma students as per technical education Kerala Syll...Basic Electronics for diploma students as per technical education Kerala Syll...
Basic Electronics for diploma students as per technical education Kerala Syll...ppkakm
 
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptxHOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptxSCMS School of Architecture
 

Recently uploaded (20)

scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
scipt v1.pptxcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
 
8086 Microprocessor Architecture: 16-bit microprocessor
8086 Microprocessor Architecture: 16-bit microprocessor8086 Microprocessor Architecture: 16-bit microprocessor
8086 Microprocessor Architecture: 16-bit microprocessor
 
Max. shear stress theory-Maximum Shear Stress Theory ​ Maximum Distortional ...
Max. shear stress theory-Maximum Shear Stress Theory ​  Maximum Distortional ...Max. shear stress theory-Maximum Shear Stress Theory ​  Maximum Distortional ...
Max. shear stress theory-Maximum Shear Stress Theory ​ Maximum Distortional ...
 
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills KuwaitKuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
 
PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and properties
 
Path loss model, OKUMURA Model, Hata Model
Path loss model, OKUMURA Model, Hata ModelPath loss model, OKUMURA Model, Hata Model
Path loss model, OKUMURA Model, Hata Model
 
Convergence of Robotics and Gen AI offers excellent opportunities for Entrepr...
Convergence of Robotics and Gen AI offers excellent opportunities for Entrepr...Convergence of Robotics and Gen AI offers excellent opportunities for Entrepr...
Convergence of Robotics and Gen AI offers excellent opportunities for Entrepr...
 
Electromagnetic relays used for power system .pptx
Electromagnetic relays used for power system .pptxElectromagnetic relays used for power system .pptx
Electromagnetic relays used for power system .pptx
 
Digital Communication Essentials: DPCM, DM, and ADM .pptx
Digital Communication Essentials: DPCM, DM, and ADM .pptxDigital Communication Essentials: DPCM, DM, and ADM .pptx
Digital Communication Essentials: DPCM, DM, and ADM .pptx
 
Augmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptxAugmented Reality (AR) with Augin Software.pptx
Augmented Reality (AR) with Augin Software.pptx
 
👉 Yavatmal Call Girls Service Just Call 🍑👄6378878445 🍑👄 Top Class Call Girl S...
👉 Yavatmal Call Girls Service Just Call 🍑👄6378878445 🍑👄 Top Class Call Girl S...👉 Yavatmal Call Girls Service Just Call 🍑👄6378878445 🍑👄 Top Class Call Girl S...
👉 Yavatmal Call Girls Service Just Call 🍑👄6378878445 🍑👄 Top Class Call Girl S...
 
School management system project Report.pdf
School management system project Report.pdfSchool management system project Report.pdf
School management system project Report.pdf
 
Query optimization and processing for advanced database systems
Query optimization and processing for advanced database systemsQuery optimization and processing for advanced database systems
Query optimization and processing for advanced database systems
 
fitting shop and tools used in fitting shop .ppt
fitting shop and tools used in fitting shop .pptfitting shop and tools used in fitting shop .ppt
fitting shop and tools used in fitting shop .ppt
 
Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)Theory of Time 2024 (Universal Theory for Everything)
Theory of Time 2024 (Universal Theory for Everything)
 
8th International Conference on Soft Computing, Mathematics and Control (SMC ...
8th International Conference on Soft Computing, Mathematics and Control (SMC ...8th International Conference on Soft Computing, Mathematics and Control (SMC ...
8th International Conference on Soft Computing, Mathematics and Control (SMC ...
 
Hostel management system project report..pdf
Hostel management system project report..pdfHostel management system project report..pdf
Hostel management system project report..pdf
 
Ground Improvement Technique: Earth Reinforcement
Ground Improvement Technique: Earth ReinforcementGround Improvement Technique: Earth Reinforcement
Ground Improvement Technique: Earth Reinforcement
 
Basic Electronics for diploma students as per technical education Kerala Syll...
Basic Electronics for diploma students as per technical education Kerala Syll...Basic Electronics for diploma students as per technical education Kerala Syll...
Basic Electronics for diploma students as per technical education Kerala Syll...
 
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptxHOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
 

Needleman-Wunsch Algorithm

  • 2. Presented By: • Proshanta Kumar Shil ID:141-15-3140 Section:B Department of CSE Daffodil International University 11-Dec-2015 2
  • 3. What is Needleman-Wunsch algorithm? The Needleman–Wunsch algorithm is an algorithm used in bioinformatics to align protein or nucleotide sequences. • It was one of the first applications of dynamic programming to compare biological sequences. • The algorithm was developed by Saul B. Needleman and Christian D. Wunsch and published in 1970. 3 11-Dec-2015
  • 4. Alignment methods • Global and local sequence alignment methods • Global : Needleman-Wunch • Local : Smith-Waterman • Database Search • BLAST • FASTA 4 11-Dec-2015
  • 5. Goals of sequence databases • To know about a newly sequenced database. • To find the similarity of a unique sequence to another gene that has a known function. • To find the similarity of a new protein in a lower organism to a protein from another species. 5 11-Dec-2015
  • 6. Alignment Algorithms • Global : Needleman-Wunch • Local : Smith-Watermann •  These two dynamic programming alignment algorithm are guaranteed to give OPTIMAL alignments •  But O(m*n) quadratic 6 11-Dec-2015
  • 7. Needleman-Wunsch Method • For example, the two hypothetical sequences • abcdefghajklm • abbdhijk • could be aligned like this • abcdefghajklm • || | | || • abbd...hijk • As shown, there are 6 matches, • 2 mismatches, and one gap of length 3. 7 11-Dec-2015
  • 8. Needleman-Wunsch Method • The alignment is scored according to a payoff matrix • $payoff = { match => $match, • mismatch => $mismatch, • gap_open => $gap_open, • gap_extend => $gap_extend }; • For correct operation, match must be positive, • and the other entries must be negative. 8 11-Dec-2015
  • 9. Needleman-Wunsch Method • Given the payoff matrix • $payoff = { match => 4, • mismatch => -3, • gap_open => -2, • gap_extend => -1 }; 9 11-Dec-2015
  • 10. Needleman-Wunsch Method • The sequences • abcdefghajklm • abbdhijk • are aligned and scored like this • a b c d e f g h a j k l m • | | | | | | • a b b d . . . h i j k • match 4 4 4 4 4 4 • mismatch -3 -3 • gap_open -2 • gap_extend -1-1-1 • for a total score of 24-6-2-3 = 13. 10 11-Dec-2015
  • 11. Steps: • 1. Initialization • 2 Matrix fill or scoring • 3. Traceback and alignment 11 11-Dec-2015
  • 12. Lets see an example… 12 11-Dec-2015
  • 13. Fill in the Table 13 11-Dec-2015 A G C A A C C Two sequences will be aligned. AGC (sequence #1) AACC (sequence #2) A simple scoring scheme will be used
  • 14. Initialization step: Create Matrix with M + 1 columns and N + 1 rows. For match=+1; Mismatch=-1; Gap=-2 14 11-Dec-2015 A G C 0 -2 -4 -6 A -2 A -4 C -6 C -8
  • 15. 15 11-Dec-2015 Fill in the Table A G C 0 -2 -4 -6 A -2 1 A -4 C -6 C -8 Matrix fill step: Each position Mi,j is defined to be the MAXIMUM score at position i,j Mi,j = MAXIMUM [ Mi-1, j-1 + si,,j (match or mismatch in the diagonal) Mi, j-1 + w (gap in sequence #1) Mi-1, j + w (gap in sequence #2)]
  • 16. Continuing the procedure 16 11-Dec-2015 A G C 0 -2 -4 -6 A -2 1 -1 -3 A -4 -1 0 -2 C -6 -3 -2 -1 C -8 -5 -4 -1
  • 17. Traceback step: Position at current cell and look at direct predecessors 17 11-Dec-2015 A G C 0 -2 -4 -6 A -2 1 -1 -3 A -4 -1 0 -2 C -6 -3 -2 -1 C -8 -5 -4 -1
  • 18. Traceback step: Position at current cell and look at direct predecessors 18 11-Dec-2015 A G C 0 -2 -4 -6 A -2 1 -1 -3 A -4 -1 0 -2 C -6 -3 -2 -1 C -8 -5 -4 -1 AG-C AAAC -AGC AAAC A-GC AAAC
  • 19. Summary • The algorithm essentially divides a large problem into a series of smaller problems and uses the solutions to the smaller problems to reconstruct a solution to the larger problem. • It is also sometimes referred to as the optimal matching algorithm and the global alignment technique. • The Needleman–Wunsch algorithm is still widely used for optimal global alignment, particularly when the quality of the global alignment is of the utmost importance. 11-Dec-2015 19