1
2
3
4
5
6 """
7 Bio.Application command line for the multiple alignment program DIALIGN2-2.
8
9 http://bibiserv.techfak.uni-bielefeld.de/dialign/welcome.html
10
11 Citations:
12
13 B. Morgenstern (2004). DIALIGN: Multiple DNA and Protein Sequence Alignment
14 at BiBiServ. Nucleic Acids Research 32, W33-W36.
15
16 Last checked against version: 2.2
17 """
18
19 from Bio import Application
20 from Bio.Application import _Option, _Argument, _Switch, AbstractCommandline
21
23 """Command line wrapper for the multiple alignment program DIALIGN2-2."""
24 - def __init__(self, cmd="dialign2-2", **kwargs):
25 self.program_name = cmd
26 self.parameters = \
27 [
28 _Switch(["-afc", "afc"], ["input"],
29 "Creates additional output file '*.afc' " + \
30 "containing data of all fragments considered " + \
31 "for alignment WARNING: this file can be HUGE !"),
32 _Switch(["-afc_v", "afc_v"], ["input"],
33 "Like '-afc' but verbose: fragments are explicitly " + \
34 "printed. WARNING: this file can be EVEN BIGGER !"),
35 _Switch(["-anc", "anc"], ["input"],
36 "Anchored alignment. Requires a file <seq_file>.anc " + \
37 "containing anchor points."),
38 _Switch(["-cs", "cs"], ["input"],
39 "If segments are translated, not only the `Watson " + \
40 "strand' but also the `Crick strand' is looked at."),
41 _Switch(["-cw", "cw"], ["input"],
42 "Additional output file in CLUSTAL W format."),
43 _Switch(["-ds", "ds"], ["input"],
44 "`dna alignment speed up' - non-translated nucleic acid " + \
45 "fragments are taken into account only if they start " + \
46 "with at least two matches. Speeds up DNA alignment at " + \
47 "the expense of sensitivity."),
48 _Switch(["-fa", "fa"], ["input"],
49 "Additional output file in FASTA format."),
50 _Switch(["-ff", "ff"], ["input"],
51 "Creates file *.frg containing information about all " + \
52 "fragments that are part of the respective optimal " + \
53 "pairwise alignmnets plus information about " + \
54 "consistency in the multiple alignment"),
55 _Option(["-fn", "fn"], ["input"],
56 None,
57 0,
58 "Output files are named <out_file>.<extension>.",
59 0),
60 _Switch(["-fop", "fop"], ["input"],
61 "Creates file *.fop containing coordinates of all " + \
62 "fragments that are part of the respective pairwise alignments."),
63 _Switch(["-fsm", "fsm"], ["input"],
64 "Creates file *.fsm containing coordinates of all " + \
65 "fragments that are part of the final alignment"),
66 _Switch(["-iw", "iw"], ["input"],
67 "Overlap weights switched off (by default, overlap " + \
68 "weights are used if up to 35 sequences are aligned). " + \
69 "This option speeds up the alignment but may lead " + \
70 "to reduced alignment quality."),
71 _Switch(["-lgs", "lgs"], ["input"],
72 "`long genomic sequences' - combines the following " + \
73 "options: -ma, -thr 2, -lmax 30, -smin 8, -nta, -ff, " + \
74 "-fop, -ff, -cs, -ds, -pst "),
75 _Switch(["-lgs_t", "lgs_t"], ["input"],
76 "Like '-lgs' but with all segment pairs assessed " + \
77 "at the peptide level (rather than 'mixed alignments' " + \
78 "as with the '-lgs' option). Therefore faster than " + \
79 "-lgs but not very sensitive for non-coding regions."),
80 _Option(["-lmax", "lmax"], ["input"],
81 lambda x: isinstance(x, int),
82 0,
83 "Maximum fragment length = x (default: x = 40 or " + \
84 "x = 120 for `translated' fragments). Shorter x " + \
85 "speeds up the program but may affect alignment quality.",
86 0),
87 _Switch(["-lo", "lo"], ["input"],
88 "(Long Output) Additional file *.log with information " + \
89 "about fragments selected for pairwise alignment and " + \
90 "about consistency in multi-alignment proceedure."),
91 _Switch(["-ma", "ma"], ["input"],
92 "`mixed alignments' consisting of P-fragments and " + \
93 "N-fragments if nucleic acid sequences are aligned."),
94 _Switch(["-mask", "mask"], ["input"],
95 "Residues not belonging to selected fragments are " + \
96 "replaced by `*' characters in output alignment " + \
97 "(rather than being printed in lower-case characters)"),
98 _Switch(["-mat", "mat"], ["input"],
99 "Creates file *mat with substitution counts derived " + \
100 "from the fragments that have been selected for alignment."),
101 _Switch(["-mat_thr", "mat_thr"], ["input"],
102 "Like '-mat' but only fragments with weight score " + \
103 "> t are considered"),
104 _Switch(["-max_link", "max_link"], ["input"],
105 "'maximum linkage' clustering used to construct " + \
106 "sequence tree (instead of UPGMA)."),
107 _Switch(["-min_link", "min_link"], ["input"],
108 "'minimum linkage' clustering used."),
109 _Option(["-mot", "mot"], ["input"],
110 None,
111 0,
112 "'motif' option.",
113 0),
114 _Switch(["-msf", "msf"], ["input"],
115 "Separate output file in MSF format."),
116 _Switch(["-n", "n"], ["input"],
117 "Input sequences are nucleic acid sequences. " + \
118 "No translation of fragments."),
119 _Switch(["-nt", "nt"], ["input"],
120 "Input sequences are nucleic acid sequences and " + \
121 "`nucleic acid segments' are translated to `peptide " + \
122 "segments'."),
123 _Switch(["-nta", "nta"], ["input"],
124 "`no textual alignment' - textual alignment suppressed. " + \
125 "This option makes sense if other output files are of " + \
126 "intrest -- e.g. the fragment files created with -ff, " + \
127 "-fop, -fsm or -lo."),
128 _Switch(["-o", "o"], ["input"],
129 "Fast version, resulting alignments may be slightly " + \
130 "different."),
131 _Switch(["-ow", "ow"], ["input"],
132 "Overlap weights enforced (By default, overlap weights " + \
133 "are used only if up to 35 sequences are aligned since " + \
134 "calculating overlap weights is time consuming)."),
135 _Switch(["-pst", "pst"], ["input"],
136 "'print status'. Creates and updates a file *.sta with " + \
137 "information about the current status of the program " + \
138 "run. This option is recommended if large data sets " + \
139 "are aligned since it allows the user to estimate the " + \
140 "remaining running time."),
141 _Switch(["-smin", "smin"], ["input"],
142 "Minimum similarity value for first residue pair " + \
143 "(or codon pair) in fragments. Speeds up protein " + \
144 "alignment or alignment of translated DNA fragments " + \
145 "at the expense of sensitivity."),
146 _Option(["-stars", "stars"], ["input"],
147 lambda x: x in range(0,10),
148 0,
149 "Maximum number of `*' characters indicating degree " + \
150 "of local similarity among sequences. By default, no " + \
151 "stars are used but numbers between 0 and 9, instead.",
152 0),
153 _Switch(["-stdo", "stdo"], ["input"],
154 "Results written to standard output."),
155 _Switch(["-ta", "ta"], ["input"],
156 "Standard textual alignment printed (overrides " + \
157 "suppression of textual alignments in special " + \
158 "options, e.g. -lgs)"),
159 _Option(["-thr", "thr"], ["input"],
160 lambda x: isinstance(x, int),
161 0,
162 "Threshold T = x.",
163 0),
164 _Switch(["-xfr", "xfr"], ["input"],
165 "'exclude fragments' - list of fragments can be " + \
166 "specified that are NOT considered for pairwise alignment"),
167 _Argument(["input"], ["input", "file"], None, 1,
168 "Input file name. Must be FASTA format")
169 ]
170 AbstractCommandline.__init__(self, cmd, **kwargs)
171