860 likes | 1.16k Views
Homology and sequence alignment. Homology. Homology = Similarity between objects due to a common ancestry. Hund = Dog, Schwein = Pig. Sequence homology. Similarity between sequences as a result of common ancestry. VLS P AV K WAKV G A HA AGHG ||| || |||| | |||| VLS E AV L WAKV E A DV AGHG.
E N D
Homology Homology = Similarity between objects due to a common ancestry Hund = Dog, Schwein = Pig
Sequence homology Similarity between sequences as a result of common ancestry. VLSPAVKWAKVGAHAAGHG ||| || |||| | |||| VLSEAVLWAKVEADVAGHG
Sequence alignment Alignment:Comparing two (pairwise) or more (multiple) sequences. Searching for a series of identical or similar characters in the sequences.
Why align? VLSPAVKWAKV ||| || |||| VLSEAVLWAKV • To detect if two sequence are homologous. If so, homology may indicate similarity in function (and structure). • Required for evolutionary studies (e.g., tree reconstruction). • To detect conservation (e.g., a tyrosine that is evolutionary conserved is more likely to be a phosphorylation site).
Sequence alignment If two sequences share a common ancestor – for example human and dog hemoglobin, we can represent their evolutionary relationship using a tree VLSPAV-WAKV ||| || |||| VLSEAVLWAKV VLSEAVLWAKV VLSPAV-WAKV
Perfect match A perfect match suggests that no change has occurred from the common ancestor (although this is not always the case). VLSPAV-WAKV ||| || |||| VLSEAVLWAKV VLSEAVLWAKV VLSPAV-WAKV
A substitution A substitution suggests that at least one change has occurred since the common ancestor (although we cannot say in which lineage it has occurred). VLSPAV-WAKV ||| || |||| VLSEAVLWAKV VLSEAVLWAKV VLSPAV-WAKV
Indel Option 1: The ancestor had L and it was lost here. In such a case, the event was a deletion. VLSEAVLWAKV VLSPAV-WAKV ||| || |||| VLSEAVLWAKV VLSEAVLWAKV VLSPAV-WAKV
Indel Option 2: The ancestor was shorter and the L was inserted here. In such a case, the event was an insertion. L VLSEAVWAKV VLSPAV-WAKV ||| || |||| VLSEAVLWAKV VLSEAVLWAKV VLSPAV-WAKV
Indel Normally, given two sequences we cannot tell whether it was an insertion or a deletion, so we term the event as an indel. Deletion? Insertion? VLSEAVLWAKV VLSPAV-WAKV
Global vs. Local Global alignment– finds the best alignment across the entire two sequences. Local alignment– finds regions of similarity in parts of the sequences. Global alignment: forces alignment in regions which differ ADLGAVFALCDRYFQ |||| |||| | ADLGRTQN-CDRYYQ Local alignment will return only regions of good alignment ADLG CDRYFQ |||| |||| | ADLG CDRYYQ
Global alignment PTK2 protein tyrosine kinase 2 of human and rhesus monkey
Proteins are comprised of domains Human PTK2 : Domain A Domain B Protein tyrosine kinase domain
Protein tyrosine kinase domain In leukocytes, a different gene for tyrosine kinase is expressed. Domain A Domain X Protein tyrosine kinase domain
The sequence similarity is restricted to a single domain PTK2 Domain A Protein tyrosine kinase domain Domain B Domain X Protein tyrosine kinase domain Leukocyte TK
Conclusions Use global alignment when the two sequences share the same overall sequence arrangement. Use local alignment to detect regions of similarity.
Pairwise alignment AAGCTGAATTCGAA AGGCTCATTTCTGA One possible alignment: AAGCTGAATT-C-GAA AGGCT-CATTTCTGA-
AAGCTGAATT-C-GAA AGGCT-CATTTCTGA- This alignment includes: 2mismatches 4 indels (gap) 10 perfect matches
Choosing an alignment for a pair of sequences Many different alignments are possible for 2 sequences: AAGCTGAATTCGAA AGGCTCATTTCTGA A-AGCTGAATTC--GAA AG-GCTCA-TTTCTGA- AAGCTGAATT-C-GAA AGGCT-CATTTCTGA- Which alignment is better?
Scoring system (naïve) Perfect match: +1 Mismatch: -2 Indel (gap): -1 AAGCTGAATT-C-GAA AGGCT-CATTTCTGA- A-AGCTGAATTC--GAA AG-GCTCA-TTTCTGA- Score: =(+1)x10 + (-2)x2 + (-1)x4= 2 Score: =(+1)x9 + (-2)x2 + (-1)x6 = -1 Higher score Better alignment
Alignment scoring - scoring of sequence similarity: • Assumes independence between positions: • each position is considered separately • Scores each position: • Positive if identical (match) • Negative if different (mismatch or gap) • Total score = sum of position scores • Can be positive or negative
Scoring system • In the example above, the choice of +1 for match,-2 for mismatch, and -1 for gap is quite arbitrary • Different scoring systems different alignments • We want a good scoring system…
DNA scoring matrices Can take into account biological phenomena such as: Transition-transversion
Amino-acid scoring matrices Take into account physico-chemical properties
Scoring gaps (I) In advanced algorithms, two gaps of one amino-acid are given a different score than one gap of two amino acids. This is solved by giving a penalty to each gap that is opened. Gap extension penalty < Gap opening penalty
Homology versus chance similarity How to check if the score is significant? A. Take the two sequences Compute score. B. Take one sequence randomly shuffle it -> find score with the second sequence. Repeat 100,000 times. If the score in A is at the top 5% of the scores in B the similarity is significant.
How close? Rule of thumb: Proteins are homologous if they are at least 25% identical (length >100) DNA sequences are homologous if they are at least 70% identical
Twilight zone < 25% identity in proteins – may be homologous and may not be…. (Note that 5% identity will be obtained completely by chance!)
Searching a sequence database Idea: In order to find homologous sequences to a sequence of interest, one should compute its pairwise alignment against all known sequences in a database, and detect the best scoring significant homologs The same idea in short: Use your sequence as a query to find homologous sequences in a sequence database
Some terminology Query sequence - the sequence with which we are searching Hit – a sequence found in the database, suspected as homologous
Query sequence: DNA or protein? For coding sequences, we can use the DNA sequence or the protein sequence to search for similar sequences. Which is preferable?
Protein is better! Selection (and hence conservation) works (mostly) at the protein level:CTTTCA = Leu-SerTTGAGT=Leu-Ser
Query type • Nucleotides: a four letter alphabet • Amino acids: a twenty letter alphabet • Two random DNA sequences will, on average, have 25% identity • Two random protein sequences will, on average, have 5% identity
Conclusion The amino-acid sequence is often preferable for homology search
How do we search a database? If each pairwise alignment takes 1/10 of a second, and if the database contains 107 sequences, it will take 106seconds = 11.5days to complete one search. 150,000 searches (at least!!) are performed per day. >82,000,000 sequence records in GenBank.
Conclusion Using the exact comparison pairwise alignment algorithm between the query and all DB entries – too slow
Heuristic Definition:a heuristic is a design to solve a problem that does not provide an exact solution (but is not too bad) but reduces the time complexity of the exact solution
BLAST BLAST - Basic Local Alignment and Search Tool A heuristic for searching a database for similar sequences
DNA or Protein All types of searches are possible Query: DNA Protein Database: DNA Protein blastn – nuc vs. nucblastp – prot vs. protblastx – translated query vs. protein databasetblastn – protein vs. translated nuc. DBtblastx – translated query vs. translated database Translated databases: trEMBLgenPept
BLAST - underlying hypothesis The underlying hypothesis: when two sequences are similar there are short ungapped regions of high similarity between them The heuristic: Discard irrelevant sequences Perform exact local alignment only with the remaining sequences
How do we discard irrelevant sequences quickly? Divide the database into words of length w (default: w = 3 for protein and w = 7 for DNA) Save the words in a look-up table that can be searched quickly WTD TDF DFG FGY GYP … WTDFGYPAILKGGTAC
BLAST: discarding sequences When the user enters a query sequence, it is also divided into words Search the database for consecutive neighboring words
Neighbor words neighbor wordsare defined according to a scoring matrix (e.g., BLOSUM62 for proteins) with a certain cutoff level GFC (20) GFB GPC (11) WAC (5)
E-value The number of times we will theoretically find an alignment with a score ≥ Y of a random sequence vs. a random database Theoretically, we could trust any result with an E-value ≤ 1 In practice – BLAST uses estimations. E-values of 10-4 and lower indicate a significant homology.E-values between 10-4 and 10-2 should be checked (similar domains, maybe non-homologous).E-values between 10-2 and 1 do not indicate a good homology