merger

Function

Description

This joins two overlapping nucleic acid sequences into one merged sequence.

It uses a global alignment algorithm (Needleman & Wunsch) to optimally align the sequences and then it creates the merged sequence from the alignment. When there is a mismatch in the alignment between the two sequences, the correct base to include in the resulting sequence is chosen by using the base from the sequence which has the best local sequence quality score. The following heuristic is used to find the sequence quality score:

If one of the bases is a 'N', then the other sequence's base is used, else:

A window size around the disputed base is used to find the local quality score. This window size is increased from 5, to 10 to 20 bases or until there is a clear decision on the best choice. If there is no best choice after using a window of 20, then the base in the first sequence is used.

To calculate the quality of a window of a sequence around a base:

N.B. This heavily discriminates against the iffy bits at the end of sequence reads.

This program was originally written to aid in the reconstruction of mRNA sequences which had been sequenced from both ends as a 5' and 3' EST (cDNA). eg. joining two reads produced by primer walking sequencing.

Care should be taken to reverse one of the sequences (e.g. using the qualifier '-sreverse2') if this is required to get them both in the correct orientation.

Because it uses a Needleman & Wunsch alignment the required memory may be greater than the available memory when attempting to merge large (cosmid-sized or greater) sequences.

The gap open and gap extension penalties have been set at a higher level than is usual (50 and 5). This was experimentally determined to give the best results with a set of poor quality EST test sequences.

Usage

Typically, one of the sequences will need to be reverse-complemented to put it into the correct orientation to make it join. For example:

% merger file1.seq file2.seq -sreverse2 -outseq merged.seq

Command line arguments


Input file format

merger reads any two sequence USAs of the same type (protein or nucleic acid.)

Output file format

The output sequence file contains the joined sequence, by default in FASTA format. Where there is a mismatch in the alignment, the chosen base is written to the output sequence in uppercase.

The output report file contains descriptions of the positions where there is a mismatch in the alignment and shows the alignment. Where there is a mismatch in the alignment, the chosen base is written in uppercase.

Data files

It reads the scoring matrix for the alignment from the standard EMBOSS 'data' directory. By default it is the file 'EBLOSUM62' (for proteins) or the file 'EDNAFULL' (for nucleic sequences).

Notes

None.

References

None.

Warnings

None.

Diagnostic Error Messages

None.

Exit status

It exits with a status of 0

Known bugs

None.

Author(s)

History

Target users

Comments