How does Clustalw Work (very simple explanation)...

(Continued from previous question...)

How does Clustalw Work (very simple explanation)?

1. Determine all pairwise alignments between sequences and the degree of similarity between them:

2. Construct a similarity tree.

3. Combine the alignments from 1 in the order specified in 2 using the rule " once a gap always a gap"

In stage 1:
1.1. clustalw uses a pairwise alignment to compute pairwise alignments.

1.2. Using the alignments from 1.1 it computes a distance.

1.2.1. The distance is commonly calculated by looking at the non-gapped positions and count the number of mistmatches between the two sequences. Then divide this value by the number of non-gapped pairs to calculate the distance. Once all distances for all pairs are calculated they go into a matrix. This follows on in stage 2.
2. Using the matrix from 1.2.1. and Neighbor-Joining, Clustalw constructs the similarity tree. The root is placed in the middle of the longest chain of consecutive edges.

3. Combine the alignments, starting from the closest related groups (going form the tips of the tree towards the root).