MrBayes Block Tutorial
This is a very short example of how to set up a MrBayes block.
Phylogenetics: MrBayes Lab
Bodega Phylogenetics Wiki - (1) MrBayes Tutorial and (2) MrBayes Tutorial
Frederik Ronquist's page of MrBayes resources - great!
The following block was generated for my Mytilus data set. This data set was a concatenated alignment of the two linked loci COI and VD1; both mtDNA. In this short example, I will show how to conduct a partitioned analysis with MrBayes.
The MrBayes block should be placed at the end of your Nexus file under your DATA block:
[ start log file and replace the existing one ]
log start filename=coivd1_haplo.log replace;
[ setting the outgroup and sets ]
charset COI = 1-399;
charset VD1 = 400-.;
partition by_gene = 2: COI, VD1;
[ model settings and unlink model parameters ]
lset applyto=(all) nst=6 rates=invgamma;
Some commands are self-explanatory (i.e., log or outgroup), but some steps need a brief explanation:
charset = with this command you can associate names with different sets of characters, in this case COI from position 1 to 399 and VD1 from position 400 to the end.
partition = in this case I had 2 sets of characters, COI and VD1, and defined them as genes with the command by_gene.
unlink = here I have unlinked the alpha shape parameter of the gamma distribution for all subsets.
lset = is used to define the structure of the model; in this case I have applied the General Time Reversible model with a proportion of invariable sites and a gamma-shaped distribution of rates across sites (nst=6 rates=invgamma) for all subsets.
prset = this command is used to define the prior probability distributions on the parameters of the model; therefore, I used JModeltest to carry out the statistical selection of the best-fit models of nucleotide substitution. With applyto= (1) or (2) I was able to define the different parameters of nucleotide substitution for the two subsets:
revmatpr = for the six substitution rates of the GTR rate matrix
statefreqpr = for the stationary nucleotide frequencies of the GTR rate matrix
pinvar = for the proportion of invariable sites
shapepr = for the shape parameter of the gamma ditribution of rate variation
Finally, the commands for the execution of the analysis:
mcmc = start the Markov chain Monte Carlo analysis with four chains (nchains = 4) - in this case the nchains command is quite unnecessary, due to the fact that 4 is the default number of chains (3 heated chains and 1 cold chain).
ngen = number of generations for which the analysis will run; in this case 2.000.000 generations
samplefreq = determines how often the chain is sampled; again, in this case every 100th generation is the default value
savebrlens = save the branch lengths when it saves the sampled tree topology
printfreq = the frequency with which the state of the chains is printed to screen
At this point I should write a tutorial of how to summarize the MCMC analysis output (i.e., the sump and sumt commands) and interpreting the subsequent results. By then, have fun with your own analysis.