Skip to content

Commit a07889f

Browse files
committed
Improve dating document and change version no to 3.0.1
1 parent 268e7ae commit a07889f

1 file changed

Lines changed: 28 additions & 47 deletions

File tree

doc/Dating.md

Lines changed: 28 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
22
layout: userdoc
33
title: "Phylogenetic Dating"
4-
author: Minh Bui, Piyumal Demotte, Rob Lanfear
5-
date: 2025-02-27
4+
author: Piyumal Demotte, Minh Bui, Rob Lanfear
5+
date: 2025-05-05
66
docid: 7
77
icon: info-circle
88
doctype: tutorial
@@ -42,14 +42,14 @@ Phylogenetic Dating
4242
Bayesian dating with MCMCtree
4343
------------------------------------------------------------
4444

45-
From IQ-TREE 2.5 onwards, we provide the functionality in IQ-TREE to infer time trees
45+
From IQ-TREE version 3.0.1 onwards, we provide the functionality in IQ-TREE to infer time trees
4646
using Bayesian MCMCtree method.
4747

4848
If you use this feature, please cite:
4949

50-
> __P. Demotte, M. Panchaksaram, N. Ly-Trong, M. dos Reis and B.Q. Minh__
50+
> __P. Demotte, M. Panchaksaram, H. Kumarasinghe, N. Ly-Trong, M. dos Reis and B.Q. Minh__
5151
>(2025) IQ2MC: A New Framework to Infer Phylogenetic Time Trees Using IQ-TREE
52-
>and MCMCtree.
52+
>and MCMCtree with Mixture Models. Submitted.
5353
5454
IQ2MC workflow for time tree inference
5555
--------------------------------------
@@ -90,7 +90,7 @@ If the alignment file is called `example.phy` and the rooted tree file is called
9090
`example_tree.nwk`,
9191

9292
```
93-
iqtree -s example.phy -m GTR+G4 -te example_tree.nwk --dating mcmctree --prefix example
93+
iqtree3 -s example.phy -m GTR+G4 -te example_tree.nwk --dating mcmctree --prefix example
9494
```
9595

9696

@@ -118,7 +118,7 @@ You can specify more parameters in the workflow to generate the control file
118118
accurately for the analysis with IQ-TREE.
119119

120120
```
121-
iqtree -s example.phy -m GTR+G4 -te example_tree.nwk --dating mcmctree --mcmc-iter 20000,200,50000 --mcmc-bds 1,1,0.5 --mcmc-clock IND
121+
iqtree3 -s example.phy -m GTR+G4 -te example_tree.nwk --dating mcmctree --mcmc-iter 20000,200,50000 --mcmc-bds 1,1,0.5 --mcmc-clock IND
122122
```
123123

124124
* `--mcmc-iter burnin,samplefreq,nsample` : use to set number of burin samples,
@@ -134,56 +134,35 @@ Currently supported clocks models are EQUAL: global clock with equal rates, IND:
134134
independent rates model with independent rates across lineages and CORR:
135135
correlated clock model with auto-correlated rates across the lineages.
136136

137-
Using partitions and Mixture models for approximate likelihood dating
137+
Using partitions and mixture models for approximate likelihood dating
138138
---------------------------------------------------------------------
139139

140140
IQ-TREE supports three partition models for approximate likelihood dating. Under
141-
the Edge-unlinked (EUL) model, IQ-TREE generates the Hessian file which contains
141+
the Edge-unlinked (EUL) model (`-Q` option), IQ-TREE generates the Hessian file which contains
142142
separate gradients and Hessian for each partition. For the Edge-linked (EL)
143-
partition model, the Hessian file contains only one gradient vector and a
144-
Hessian as branches are shared across partitions.
143+
partition model (`-p` option), the Hessian file contains only one gradient vector and a
144+
Hessian as branches are shared across partitions. See [Complex Models](Complex-Models)
145+
for how to specify partition and mixture models. If your partition file is called `example.nex`:
145146

146-
Since IQ-TREE supports RAxML and NEXUS style partitions input file, you can use
147-
partitions defined in the following format.
148-
149-
```
150-
DNA, part1 = 1-100
151-
DNA, part2 = 101-450
152-
```
153-
If your partition file is called `example.nex`,
154-
155-
```
156-
iqtree -s example.phy -Q example.nex -m GTR+G4 -te example_tree.nwk --dating mcmctree
157147
```
158-
159-
Here, IQ-TREE generates the Hessian file using the `GTR+G4` model for all
160-
partitions. If you need to use different models for each partition, you need to
161-
create a more flexible NEXUS file like the following.
162-
163-
```
164-
#nexus
165-
begin sets;
166-
charset part1 = 1-100;
167-
charset part2 = 101-450;
168-
charpartition mine = GTR+G4:part1, HKY:part2;
169-
end;
148+
# -Q option is to specify egde-unlinked partition model
149+
iqtree3 -s example.phy -Q example.nex -m GTR+G4 -te example_tree.nwk --dating mcmctree
170150
```
171-
Here, IQ-TREE uses `GTR+G4` model for partition 1, and `HKY` model for partition
172-
2 respectively. Using `-q` and `-p` options, you can generate the Hessian file
173-
which considers `edge-linked equal branch partition models` and `edge-linked
174-
proportional branch length models` respectively.
175151

176152
IQ-TREE also supports mixture models for the Hessian file generation. You can
177153
simply specify DNA or Amino Acid Mixture model as following,
178154

179155
```
180-
iqtree -s example.phy -m "MIX{GTR,HKY}+G4" -te example_tree.nwk –-dating mcmctree
156+
iqtree3 -s example.phy -m "MIX{GTR,HKY}+G4" -te example_tree.nwk –-dating mcmctree
181157
```
158+
(Or you can also invoke [MixtureFinder](Complex-Models#mixturefinder) with `-m MIX+MFP` to determine mixture models automatically).
159+
182160
If you need to use an Amino Acid profile mixture model such as C60 model,
183161

184162
```
185-
iqtree -s example.phy -m LG+G4+C60 -te example_tree.nwk –-dating mcmctree
163+
iqtree3 -s example_aa.phy -m LG+G4+C60 -te example_aa_tree.nwk –-dating mcmctree
186164
```
165+
187166
If you are using ModelFinder or MixtureFinder, you need to follow a two-step
188167
approach. First, you can estimate the best-fit model for the data using
189168
ModelFinder or MixtureFinder. Then, the Hessian file can be generated using
@@ -192,17 +171,19 @@ ModelFinder or MixtureFinder. Then, the Hessian file can be generated using
192171
How to run MCMCtree
193172
-------------------
194173

195-
You can directly run MCMCtree from the control file generated by IQ-TREE in step
196-
2. The command to run MCMCtree with the control file is,
174+
You need to download a modified version of MCMCTree from <https://github.com/iqtree/paml>.
175+
This version has some changes to make the workflow more convenient.
176+
You can then directly run MCMCtree from the control file generated by IQ-TREE in step 2.
177+
The command to run MCMCtree with the control file is:
197178

198179
```
199180
mcmctree example.mcmctree.ctl
200181
```
201182

202183

203-
The control file generated by IQ-TREE has the following format. You can simply
204-
edit the control file as necessary. For an example you may need to increase
205-
burin and sample frequency for MCMC convergence.
184+
The control file generated by IQ-TREE has the following format. You can
185+
edit the control file before running `mcmctree` as necessary. For example, you can increase
186+
burnin and sample frequency for MCMC convergence.
206187

207188
```
208189
seed = -1 * The computer’s current time is used when seed < 0.
@@ -252,8 +233,8 @@ alpha_gamma = 1 1 * alpha and beta parameter of Gamma distribution for heter
252233

253234
Note that, if you generate the `hessain file` from IQ-TREE, it is necessary to
254235
use the rooted tree file generated by IQ-TREE to be used in MCMCtree. The
255-
`ckpfile` and `hessianfile` options are new and only work for the PAML release
256-
in IQ-TREE (https://github.com/iqtree/paml). If you use another MCMCtree
236+
`ckpfile` and `hessianfile` options are new and only work with our modified
237+
[PAML code](https://github.com/iqtree/paml). If you use another MCMCtree
257238
version/release, you can simply remove those options from control file and
258239
rename the `hessian file` to `in.BV` to run MCMCtree without any errors.
259240

0 commit comments

Comments
 (0)