The CloseGaps algorithm is as follows: Loop over every pair of consecutive contigs in every supercontig. For each pair of contigs, attempt to find an alignment between them; if an alignment is found, use it to merge the contigs. The methods of finding an alignment are, in order:
- Look for an alignment using AlignTwoBasevectors.
- Look for a shared mutmer with length ≥ 80 bp, error rate ≤ 3%, and pairing distortion ≤ 4 sd.
- Look for a shared mutmer with length ≥ 200 bp, error rate ≤ 1.5%, and pairing distortion ≤ 2 sd.
- Look for a shared sequence of C's or G's of length ≥ 14, with pairing distortion ≤ 2 sd.