values.h
Go to the documentation of this file.
1 /* *****************************************************************************
2 
3  trimAl v2.0: a tool for automated alignment trimming in large-scale
4  phylogenetics analyses.
5 
6  readAl v2.0: a tool for automated alignment conversion among different
7  formats.
8 
9  2009-2019
10  Fernandez-Rodriguez V. (victor.fernandez@bsc.es)
11  Capella-Gutierrez S. (salvador.capella@bsc.es)
12  Gabaldon, T. (tgabaldon@crg.es)
13 
14  This file is part of trimAl/readAl.
15 
16  trimAl/readAl are free software: you can redistribute it and/or modify
17  it under the terms of the GNU General Public License as published by
18  the Free Software Foundation, the last available version.
19 
20  trimAl/readAl are distributed in the hope that it will be useful,
21  but WITHOUT ANY WARRANTY; without even the implied warranty of
22  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23  GNU General Public License for more details.
24 
25  You should have received a copy of the GNU General Public License
26  along with trimAl/readAl. If not, see <http://www.gnu.org/licenses/>.
27 
28 ***************************************************************************** */
29 #ifndef VALUES
30 #define VALUES
31 #ifdef SIMMatrix
32 
33 /* Characters used for different alignments type */
34 char listNTSym[6] = "ACGTU";
35 
36 char listAASym[21] = "ARNDCQEGHILKMFPSTWYV";
37 
38 char listNTDegenerateSym[16] = "ACGTURYKMSWBDHV";
39 
40 /* Characters used to indicate indeterminations */
41 char protein_wildcards[3] = "BX";
42 
43 /* Pyrrolysine: 'O' > 'TAG' */
44 /* Selenocysteine: 'U' > 'TGA' */
45 char protein_alternative_aminoacids[3] = "UO";
46 
47 /* Default Identity Matrix for Canonical Nucleotides */
48 float defaultNTMatrix[5][5] = {
49  {1, 0, 0, 0, 0},
50  {0, 1, 0, 0, 0},
51  {0, 0, 1, 0, 0},
52  {0, 0, 0, 1, 0},
53  {0, 0, 0, 0, 1}
54 };
55 
56 float defaultNTDegeneratedMatrix[15][15] = {
57 /* A: adenosine (A) C: cytidine (C) G: guanine (G) T: thymidine (T) U: uridine (U)
58  * R: purine (G | A) Y: pyrimidine (C | T/u) K: keto (G | T/u) M: amino (A | C) S: strong (G | C)
59  * W: weak (A | T/u) B: not A (G | C | T/u) D: not C (G | A | T/u) H: not G (A | C | T/u) V: not T/u (G | C | A) */
60  { 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},
61  { 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},
62  { 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},
63  { 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},
64  { 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},
65  { 1/4., 0.0, 1/4., 0.0, 0.0, 1/4., 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},
66  { 0.0, 1/4., 0.0, 1/4., 1/4., 0.0, 1/4., 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},
67  { 0.0, 0.0, 1/4., 1/4., 1/4., 0.0, 0.0, 1/4., 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},
68  { 1/4., 1/4., 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1/4., 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},
69  { 0.0, 1/4., 1/4., 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1/4., 0.0, 0.0, 0.0, 0.0, 0.0},
70  { 1/4., 0.0, 0.0, 1/4., 1/4., 0.0, 0.0, 0.0, 0.0, 0.0, 1/4., 0.0, 0.0, 0.0, 0.0},
71  { 0.0, 1/6., 1/6., 1/6., 1/6., 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1/6., 0.0, 0.0, 0.0},
72  { 1/6., 0.0, 1/6., 1/6., 1/6., 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1/6., 0.0, 0.0},
73  { 1/6., 1/6., 0.0, 1/6., 1/6., 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1/6., 0.0},
74  { 1/6., 1/6., 1/6., 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1/6.}
75 };
76 
77 /* BLOSUM62 Similarity Matrix */
78 float defaultAAMatrix[20][20] = {
79  { 4, -1, -2, -2, 0, -1, -1, 0, -2, -1, -1, -1, -1, -2, -1, 1, 0, -3, -2, 0},
80  { -1, 5, 0, -2, -3, 1, 0, -2, 0, -3, -2, 2, -1, -3, -2, -1, -1, -3, -2, -3},
81  { -2, 0, 6, 1, -3, 0, 0, 0, 1, -3, -3, 0, -2, -3, -2, 1, 0, -4, -2, -3},
82  { -2, -2, 1, 6, -3, 0, 2, -1, -1, -3, -4, -1, -3, -3, -1, 0, -1, -4, -3, -3},
83  { 0, -3, -3, -3, 9, -3, -4, -3, -3, -1, -1, -3, -1, -2, -3, -1, -1, -2, -2, -1},
84  { -1, 1, 0, 0, -3, 5, 2, -2, 0, -3, -2, 1, 0, -3, -1, 0, -1, -2, -1, -2},
85  { -1, 0, 0, 2, -4, 2, 5, -2, 0, -3, -3, 1, -2, -3, -1, 0, -1, -3, -2, -2},
86  { 0, -2, 0, -1, -3, -2, -2, 6, -2, -4, -4, -2, -3, -3, -2, 0, -2, -2, -3, -3},
87  { -2, 0, 1, -1, -3, 0, 0, -2, 8, -3, -3, -1, -2, -1, -2, -1, -2, -2, 2, -3},
88  { -1, -3, -3, -3, -1, -3, -3, -4, -3, 4, 2, -3, 1, 0, -3, -2, -1, -3, -1, 3},
89  { -1, -2, -3, -4, -1, -2, -3, -4, -3, 2, 4, -2, 2, 0, -3, -2, -1, -2, -1, 1},
90  { -1, 2, 0, -1, -3, 1, 1, -2, -1, -3, -2, 5, -1, -3, -1, 0, -1, -3, -2, -2},
91  { -1, -1, -2, -3, -1, 0, -2, -3, -2, 1, 2, -1, 5, 0, -2, -1, -1, -1, -1, 1},
92  { -2, -3, -3, -3, -2, -3, -3, -3, -1, 0, 0, -3, 0, 6, -4, -2, -2, 1, 3, -1},
93  { -1, -2, -2, -1, -3, -1, -1, -2, -2, -3, -3, -1, -2, -4, 7, -1, -1, -4, -3, -2},
94  { 1, -1, 1, 0, -1, 0, 0, 0, -1, -2, -2, 0, -1, -2, -1, 4, 1, -3, -2, -2},
95  { 0, -1, 0, -1, -1, -1, -1, -2, -2, -1, -1, -1, -1, -2, -1, 1, 5, -2, -2, 0},
96  { -3, -3, -4, -4, -2, -2, -3, -2, -2, -3, -2, -3, -1, 1, -4, -3, -2, 11, 2, -3},
97  { -2, -2, -2, -3, -2, -1, -2, -3, 2, -1, -1, -2, -1, 3, -3, -2, -2, 2, 7, -1},
98  { 0, -3, -3, -3, -1, -2, -2, -3, -3, 3, 1, -2, 1, -1, -2, -2, 0, -3, -1, 4}
99 };
100 
101 
102 /* Alternative matrixes */
103 
104 // Nucleotides
105 float alternative_1_NTDegeneratedMatrix[15][15] = {
106  { 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
107  { 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
108  { 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
109  { 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
110  { 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
111  { 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0},
112  { 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0},
113  { 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0},
114  { 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0},
115  { 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0},
116  { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0},
117  { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0},
118  { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0},
119  { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0},
120  { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1}
121 };
122 
123 #endif
124 #endif