3
|
1 <?xml version="1.0"?>
|
|
2 <tool id="mrbayes" name="MrBayes">
|
|
3 <description>with options and commands</description>
|
4
|
4 <command> mb $command_file > $outfile
|
5
|
5 ## print list of avaialble variables
|
|
6 #silent sys.stderr.write("\n \n \n ======== Cheetah template variables ========\n")
|
4
|
7 #for k,v in $searchList[2].items()
|
|
8 #silent sys.stderr.write(" %s = %s\n" % (str(k), str(v) ))
|
|
9 #end for
|
5
|
10 #silent sys.stderr.write("======== End of Cheetah template variables ========\n \n \n")
|
4
|
11 </command>
|
3
|
12 <inputs>
|
|
13 <param name="data" type="data" format="nex" label="Nexus input file"/>
|
|
14
|
5
|
15 <param name="filename" type="text" label="Output filename" size="10" value=""
|
|
16 help="Output files will be named this with .p, .t, .mcmc extensions. Use to avoid overwriting files when running repeated analyses on the same dataset." />
|
|
17
|
|
18 <param name="ngen" type="integer" label="<hr>Number of generations" value="10000" >
|
|
19 <validator type="in_range" min="1" max="inf" message="Must be greater than or equal to 1"/>
|
|
20 </param>
|
|
21 <param name="nchain" type="integer" label="Number of chains" value="2" >
|
|
22 <validator type="in_range" min="1" max="inf" message="Must be greater than or equal to 1"/>
|
|
23 </param>
|
|
24 <param name="nrun" type="integer" label="Number of runs" value="2" >
|
|
25 <validator type="in_range" min="1" max="inf" message="Must be greater than or equal to 1"/>
|
|
26 </param>
|
|
27
|
|
28 <param name="outgroup" type="text" label="<hr>Outgroup" size="10" value="1"
|
3
|
29 help="The name or number identifying one taxon from the data." />
|
|
30 <param name="model" type="select" label="Choose model">
|
|
31 <sanitizer sanitize="False" />
|
|
32 <option value="lset nst=6" >GRT</option>
|
|
33 <option value="lset nst=6; prset statefreqpr=fixed(equal)">SYM</option>
|
|
34 <option value="lset nst=2" >HKY</option>
|
|
35 <option value="lset nst=2; prset statefreqpr=fixed(equal)">K2P</option>
|
|
36 <option value="lset nst=1" >F81</option>
|
|
37 <option value="lset nst=1; prset statefreqpr=fixed(equal)">JC </option>
|
|
38 <option value="lset nst=mixed" >Mixed </option>
|
|
39 <help>Models are defined below and are only valid for nucleotide data.</help>
|
|
40 </param>
|
|
41 <param name="rates" type="select" label="Choose rates">
|
|
42 <option value="equal"/>
|
|
43 <option value="gamma"/>
|
|
44 <option value="propinv"/>
|
|
45 <option value="invgamma"/>
|
|
46 <option value="adgamma"/>
|
|
47 </param>
|
5
|
48 <param name="samplefreq" type="integer" label="<hr>Sample frequency" value="500" >
|
3
|
49 <validator type="in_range" min="1" max="inf" message="Must be greater than or equal to 1"/>
|
|
50 <help>Frequency with which output it written to files." </help>
|
|
51 </param>
|
|
52 <param name="printfreq" type="integer" label="Print frequency" value="500" >
|
|
53 <validator type="in_range" min="1" max="inf" message="Must be greater than or equal to 1"/>
|
|
54 <help>Frequency with which output is printed to the screen.</help>
|
|
55 </param>
|
|
56 <param name="burninfrac" type="float" label="Burn-in fraction" value="0.25">
|
|
57 <validator type="in_range" min="0.01" max=".50" message="Must be between 0.01 and .50"/>
|
|
58 <help>Fraction of samples to discard when summarizing. </help>
|
|
59 </param>
|
|
60 <param name="stoprule" type="select" label="Stop rule?" >
|
|
61 <option value="no">No</option>
|
|
62 <option value="yes">Yes</option>
|
|
63 </param>
|
|
64
|
5
|
65 <param name="sump" type="boolean" truevalue="sump;" falsevalue="" label="<hr>Include sump?"
|
3
|
66 help="Summarizes sampled parameter value."/>
|
|
67 <param name="sumt" type="boolean" truevalue="sumt;" falsevalue="" label="Include sumt?"
|
|
68 help="Summarizes the trees."/>
|
5
|
69 <param name="plot" type="boolean" truevalue="plot" falsevalue="" label="Include plot?"
|
3
|
70 help="Creates an x-y graph of the parameter over the course of the chain."/>
|
|
71
|
5
|
72 <param name="checkfreq" type="integer" label="<hr>Checkpoint frequency" value="100000" >
|
|
73 <validator type="in_range" min="100" max="inf" message="Must be greater than or equal to 100"/>
|
|
74 <help>Frequency with which checkpoints are written. Used for continuing analysis with append.</help>
|
|
75 </param>
|
4
|
76 <param name="append" type="boolean" truevalue="mcmcp append=yes" falsevalue="mcmcp append=no" label="Append to last checkpoint?"
|
5
|
77 help="Requires .ckp file (i.e. that number of generations > checkpoint frequency for previous analysis)." />
|
4
|
78
|
3
|
79 </inputs>
|
|
80
|
|
81 <configfiles>
|
|
82 <configfile name="command_file">
|
|
83 begin mrbayes;
|
|
84 set quitonerror=no;
|
|
85 execute $data;
|
|
86 outgroup $outgroup;
|
|
87 $model;
|
|
88 lset rates=$rates;
|
5
|
89 #if str($filename) != ""
|
|
90 mcmcp filename=$filename;
|
|
91 #end if#
|
3
|
92 mcmcp ngen=$ngen nrun=$nrun nchain=$nchain checkfreq=$checkfreq samplefreq=$samplefreq printfreq=$printfreq stoprule=$stoprule burninfrac=$burninfrac;
|
4
|
93 #if int($ngen) >= int($checkfreq)
|
5
|
94 $append;
|
4
|
95 #end if#
|
3
|
96 mcmc;
|
|
97 $sump
|
|
98 $sumt
|
5
|
99 #if str($plot) == "plot"
|
|
100 plot;
|
|
101 #end if#
|
3
|
102 end;
|
|
103 </configfile>
|
|
104 </configfiles>
|
|
105
|
|
106 <outputs>
|
|
107 <data name="outfile" format="txt"/>
|
|
108 </outputs>
|
|
109
|
|
110 <requirements>
|
|
111 <requirement version="3.2.1" type="binary">mb</requirement>
|
|
112 </requirements>
|
|
113 <help>
|
|
114
|
|
115 .. class:: warningmark
|
|
116
|
4
|
117 This tool takes as input a Nexus file (.nex), described here_, that should only contain a data block, without commands. If a command block exists in the file, it will be executed first, followed by the ones specified above.
|
3
|
118
|
|
119 .. _here: http://en.wikipedia.org/wiki/Nexus_file.
|
|
120
|
|
121 -----
|
|
122
|
|
123 **What it does**
|
|
124
|
|
125 MrBayes is a program for Bayesian inference and model choice across a wide range of phylogenetic and evolutionary models. MrBayes uses Markov chain Monte Carlo (MCMC) methods to estimate the posterior distribution of model parameters.
|
|
126
|
4
|
127 See the manual_ or the `command reference`_ for more information.
|
|
128
|
|
129 .. _manual: http://mrbayes.sourceforge.net/manual.php
|
|
130 .. _command reference: http://mrbayes.sourceforge.net/commref_mb3.2.pdf
|
|
131
|
3
|
132 -----
|
|
133
|
|
134 **Model Definitions**
|
|
135
|
|
136 Models are defined by the following MrBayes options::
|
|
137
|
|
138 GRT: lset nst=6;
|
|
139 SYM: lset nst=6; prset statefreqpr=fixed(equal);
|
|
140 HKY: lset nst=2;
|
|
141 K2P: lset nst=2; prset statefreqpr=fixed(equal);
|
|
142 F81: lset nst=1;
|
|
143 JC: lset nst=1; prset statefreqpr=fixed(equal);
|
|
144 Mixed: lset nst=mixed;
|
|
145
|
|
146 Each model makes different assumptions about nucelotide substitution rates and state frequencies.
|
|
147
|
|
148 The mixed model performs Markov chain sampling over the space of all possible reversible substitution models, by grouping the six rates in various combinations.
|
|
149
|
|
150 -----
|
|
151
|
|
152 .. class:: infomark
|
|
153
|
5
|
154 **Tip for repetitive analyses**
|
|
155
|
|
156 Note that running the same analysis on the same dataset in Galaxy will overwrite .p, .t, and .mcmc files for that dataset. This can be avoided by copying the dataset or re-uploading it, or by specifying a new filename.
|
|
157
|
|
158 .. class:: infomark
|
|
159
|
4
|
160 **Tip for using append**
|
3
|
161
|
4
|
162 If you want to use the append functionality, all parameters will have to be identical to your initial analysis. The easiest way to ensure this is by using the blue "Run this job again" arrow on the dataset, and checking the additional append box. Note also that ngen will be the total number of generations, not the number of generations to add, so you should increase this value except if a run was interrupted. Selecting append while checkfreq > ngen will have no effect.
|
3
|
163 </help>
|
|
164 </tool>
|
|
165
|