Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
196 lines (166 sloc) 14.3 KB
<!-- Model: Birth-death skyline model (with contemporaneous sampling) -->
<!-- Source: Stadler T, Kühnert D, Bonhoeffer S, Drummond AJ (2013) Birth-death skyline plot reveals temporal changes of epidemic spread in HIV and HCV. PNAS 110: 228–233. -->
<!-- BEAST version: Runs on BEAST 2.1.0 - see beast2.org for downloads -->
<beast namespace="beast.core:beast.evolution.alignment:beast.evolution.tree.coalescent:beast.core.util:beast.evolution.nuc:beast.evolution.operators:beast.evolution.sitemodel:beast.evolution.substitutionmodel:beast.evolution.likelihood:beast.evolution.speciation:beast.core.parameter" version="2.0">
<!-- The sequence alignment -->
<!-- ntax=6 nchar=768 -->
<!-- npatterns=69 -->
<data id="alignment" dataType="nucleotide">
<sequence taxon="human">
AGAAATATGTCTGATAAAAGAGTTACTTTGATAGAGTAAATAATAGGAGCTTAAACCCCCTTATTTCTACTAGGACTATGAGAATCGAACCCATCCCTGAGAATCCAAAATTCTCCGTGCCACCTATCACACCCCATCCTAAGTAAGGTCAGCTAAATAAGCTATCGGGCCCATACCCCGAAAATGTTGGTTATACCCTTCCCGTACTAAGAAATTTAGGTTAAATACAGACCAAGAGCCTTCAAAGCCCTCAGTAAGTTG-CAATACTTAATTTCTGTAAGGACTGCAAAACCCCACTCTGCATCAACTGAACGCAAATCAGCCACTTTAATTAAGCTAAGCCCTTCTAGACCAATGGGACTTAAACCCACAAACACTTAGTTAACAGCTAAGCACCCTAATCAAC-TGGCTTCAATCTAAAGCCCCGGCAGG-TTTGAAGCTGCTTCTTCGAATTTGCAATTCAATATGAAAA-TCACCTCGGAGCTTGGTAAAAAGAGGCCTAACCCCTGTCTTTAGATTTACAGTCCAATGCTTCA-CTCAGCCATTTTACCACAAAAAAGGAAGGAATCGAACCCCCCAAAGCTGGTTTCAAGCCAACCCCATGGCCTCCATGACTTTTTCAAAAGGTATTAGAAAAACCATTTCATAACTTTGTCAAAGTTAAATTATAGGCT-AAATCCTATATATCTTA-CACTGTAAAGCTAACTTAGCATTAACCTTTTAAGTTAAAGATTAAGAGAACCAACACCTCTTTACAGTGA
</sequence>
<sequence taxon="chimp">
AGAAATATGTCTGATAAAAGAATTACTTTGATAGAGTAAATAATAGGAGTTCAAATCCCCTTATTTCTACTAGGACTATAAGAATCGAACTCATCCCTGAGAATCCAAAATTCTCCGTGCCACCTATCACACCCCATCCTAAGTAAGGTCAGCTAAATAAGCTATCGGGCCCATACCCCGAAAATGTTGGTTACACCCTTCCCGTACTAAGAAATTTAGGTTAAGCACAGACCAAGAGCCTTCAAAGCCCTCAGCAAGTTA-CAATACTTAATTTCTGTAAGGACTGCAAAACCCCACTCTGCATCAACTGAACGCAAATCAGCCACTTTAATTAAGCTAAGCCCTTCTAGATTAATGGGACTTAAACCCACAAACATTTAGTTAACAGCTAAACACCCTAATCAAC-TGGCTTCAATCTAAAGCCCCGGCAGG-TTTGAAGCTGCTTCTTCGAATTTGCAATTCAATATGAAAA-TCACCTCAGAGCTTGGTAAAAAGAGGCTTAACCCCTGTCTTTAGATTTACAGTCCAATGCTTCA-CTCAGCCATTTTACCACAAAAAAGGAAGGAATCGAACCCCCTAAAGCTGGTTTCAAGCCAACCCCATGACCTCCATGACTTTTTCAAAAGATATTAGAAAAACTATTTCATAACTTTGTCAAAGTTAAATTACAGGTT-AACCCCCGTATATCTTA-CACTGTAAAGCTAACCTAGCATTAACCTTTTAAGTTAAAGATTAAGAGGACCGACACCTCTTTACAGTGA
</sequence>
<sequence taxon="bonobo">
AGAAATATGTCTGATAAAAGAATTACTTTGATAGAGTAAATAATAGGAGTTTAAATCCCCTTATTTCTACTAGGACTATGAGAGTCGAACCCATCCCTGAGAATCCAAAATTCTCCGTGCCACCTATCACACCCCATCCTAAGTAAGGTCAGCTAAATAAGCTATCGGGCCCATACCCCGAAAATGTTGGTTATACCCTTCCCGTACTAAGAAATTTAGGTTAAACACAGACCAAGAGCCTTCAAAGCTCTCAGTAAGTTA-CAATACTTAATTTCTGTAAGGACTGCAAAACCCCACTCTGCATCAACTGAACGCAAATCAGCCACTTTAATTAAGCTAAGCCCTTCTAGATTAATGGGACTTAAACCCACAAACATTTAGTTAACAGCTAAACACCCTAATCAGC-TGGCTTCAATCTAAAGCCCCGGCAGG-TTTGAAGCTGCTTCTTTGAATTTGCAATTCAATATGAAAA-TCACCTCAGAGCTTGGTAAAAAGAGGCTTAACCCCTGTCTTTAGATTTACAGTCCAATGCTTCA-CTCAGCCATTTTACCACAAAAAAGGAAGGAATCGAACCCCCTAAAGCTGGTTTCAAGCCAACCCCATGACCCCCATGACTTTTTCAAAAGATATTAGAAAAACTATTTCATAACTTTGTCAAAGTTAAATTACAGGTT-AAACCCCGTATATCTTA-CACTGTAAAGCTAACCTAGCATTAACCTTTTAAGTTAAAGATTAAGAGGACCAACACCTCTTTACAGTGA
</sequence>
<sequence taxon="gorilla">
AGAAATATGTCTGATAAAAGAGTTACTTTGATAGAGTAAATAATAGAGGTTTAAACCCCCTTATTTCTACTAGGACTATGAGAATTGAACCCATCCCTGAGAATCCAAAATTCTCCGTGCCACCTGTCACACCCCATCCTAAGTAAGGTCAGCTAAATAAGCTATCGGGCCCATACCCCGAAAATGTTGGTCACATCCTTCCCGTACTAAGAAATTTAGGTTAAACATAGACCAAGAGCCTTCAAAGCCCTTAGTAAGTTA-CAACACTTAATTTCTGTAAGGACTGCAAAACCCTACTCTGCATCAACTGAACGCAAATCAGCCACTTTAATTAAGCTAAGCCCTTCTAGATCAATGGGACTCAAACCCACAAACATTTAGTTAACAGCTAAACACCCTAGTCAAC-TGGCTTCAATCTAAAGCCCCGGCAGG-TTTGAAGCTGCTTCTTCGAATTTGCAATTCAATATGAAAT-TCACCTCGGAGCTTGGTAAAAAGAGGCCCAGCCTCTGTCTTTAGATTTACAGTCCAATGCCTTA-CTCAGCCATTTTACCACAAAAAAGGAAGGAATCGAACCCCCCAAAGCTGGTTTCAAGCCAACCCCATGACCTTCATGACTTTTTCAAAAGATATTAGAAAAACTATTTCATAACTTTGTCAAGGTTAAATTACGGGTT-AAACCCCGTATATCTTA-CACTGTAAAGCTAACCTAGCGTTAACCTTTTAAGTTAAAGATTAAGAGTATCGGCACCTCTTTGCAGTGA
</sequence>
<sequence taxon="orangutan">
AGAAATATGTCTGACAAAAGAGTTACTTTGATAGAGTAAAAAATAGAGGTCTAAATCCCCTTATTTCTACTAGGACTATGGGAATTGAACCCACCCCTGAGAATCCAAAATTCTCCGTGCCACCCATCACACCCCATCCTAAGTAAGGTCAGCTAAATAAGCTATCGGGCCCATACCCCGAAAATGTTGGTTACACCCTTCCCGTACTAAGAAATTTAGGTTA--CACAGACCAAGAGCCTTCAAAGCCCTCAGCAAGTCA-CAGCACTTAATTTCTGTAAGGACTGCAAAACCCCACTTTGCATCAACTGAGCGCAAATCAGCCACTTTAATTAAGCTAAGCCCTCCTAGACCGATGGGACTTAAACCCACAAACATTTAGTTAACAGCTAAACACCCTAGTCAAT-TGGCTTCAGTCCAAAGCCCCGGCAGGCCTTAAAGCTGCTCCTTCGAATTTGCAATTCAACATGACAA-TCACCTCAGGGCTTGGTAAAAAGAGGTCTGACCCCTGTTCTTAGATTTACAGCCTAATGCCTTAACTCGGCCATTTTACCGCAAAAAAGGAAGGAATCGAACCTCCTAAAGCTGGTTTCAAGCCAACCCCATAACCCCCATGACTTTTTCAAAAGGTACTAGAAAAACCATTTCGTAACTTTGTCAAAGTTAAATTACAGGTC-AGACCCTGTGTATCTTA-CATTGCAAAGCTAACCTAGCATTAACCTTTTAAGTTAAAGACTAAGAGAACCAGCCTCTCTTTGCAATGA
</sequence>
<sequence taxon="siamang">
AGAAATACGTCTGACGAAAGAGTTACTTTGATAGAGTAAATAACAGGGGTTTAAATCCCCTTATTTCTACTAGAACCATAGGAGTCGAACCCATCCTTGAGAATCCAAAACTCTCCGTGCCACCCGTCGCACCCTGTTCTAAGTAAGGTCAGCTAAATAAGCTATCGGGCCCATACCCCGAAAATGTTGGTTATACCCTTCCCATACTAAGAAATTTAGGTTAAACACAGACCAAGAGCCTTCAAAGCCCTCAGTAAGTTAACAAAACTTAATTTCTGCAAGGGCTGCAAAACCCTACTTTGCATCAACCGAACGCAAATCAGCCACTTTAATTAAGCTAAGCCCTTCTAGATCGATGGGACTTAAACCCATAAAAATTTAGTTAACAGCTAAACACCCTAAACAACCTGGCTTCAATCTAAAGCCCCGGCAGA-GTTGAAGCTGCTTCTTTGAACTTGCAATTCAACGTGAAAAATCACTTCGGAGCTTGGCAAAAAGAGGTTTCACCTCTGTCCTTAGATTTACAGTCTAATGCTTTA-CTCAGCCACTTTACCACAAAAAAGGAAGGAATCGAACCCTCTAAAACCGGTTTCAAGCCAGCCCCATAACCTTTATGACTTTTTCAAAAGATATTAGAAAAACTATTTCATAACTTTGTCAAAGTTAAATCACAGGTCCAAACCCCGTATATCTTATCACTGTAGAGCTAGACCAGCATTAACCTTTTAAGTTAAAGACTAAGAGAACTACCGCCTCTTTACAGTGA
</sequence>
</data>
<tree spec="beast.util.ClusterTree" clusterType="upgma" taxa="@alignment" id="tree"/>
<BirthDeathSkylineModel spec="BirthDeathSkylineModel" id="birthDeath" tree="@tree" contemp="true">
<parameter name="origin" id="origin" value ="100" lower="0."/>
<!-- dimension of reproductiveNumber, becomeUninfectiousRate and samplingProportion must be either equal to intervalNumber, or 1 (i.e. rate is constant over time) -->
<parameter name="reproductiveNumber" id="reproductiveNumber" value="2" lower="0." dimension ="10"/>
<parameter name="becomeUninfectiousRate" id="becomeUninfectiousRate" value="1" lower="0." dimension ="10"/>
<parameter name="samplingProportion" id="samplingProportion" value="0."/>
<parameter name="rho" id="rho" value="1e-6" lower="0." upper="1."/>
</BirthDeathSkylineModel>
<siteModel gammaCategoryCount="4" id="SiteModel" proportionInvariant="@proportionInvariant" spec="SiteModel">
<parameter dimension="1" id="mutationRate" name="mutationRate" value="1.0"/>
<parameter dimension="1" id="gammaShape" name="shape" value="0.5" lower="0.0" upper="1000.0"/>
<substModel id="gtr" rateAC="@rateAC" rateGT="@rateGT" rateAT="@rateAT" rateCG="@rateCG" rateCT="@rateCT" spec="GTR">
<parameter dimension="1" id="rateAG" lower="0.0" name="rateAG" value="1.0"/>
<frequencies estimate="true" id="freqs" spec="Frequencies">
<parameter name='frequencies' id='freqParameter' value='0.25' dimension='4' lower="0." upper="1."/>
</frequencies>
</substModel>
</siteModel>
<branchRateModel id="StrictClock" spec="beast.evolution.branchratemodel.StrictClockModel">
<parameter dimension="1" id="clock.rate" name="clock.rate" value="0.1" lower="0." upper="100."/>
</branchRateModel>
<distribution id="posterior" spec="util.CompoundDistribution">
<distribution id="prior" spec="util.CompoundDistribution">
<distribution id="BDlikelihood" spec="util.CompoundDistribution">
<distribution idref="birthDeath"/>
</distribution>
<!-- this prior distribution corresponds to a probability of being sampled at present of 0.01 % -->
<distribution id="rho_prior" spec="beast.math.distributions.Prior" x="@rho">
<distr spec="beast.math.distributions.Beta" alpha="1." beta="9999." offset="0."/>
</distribution>
<distribution id='origin_Prior' x="@origin" spec='beast.math.distributions.Prior'>
<distr spec='beast.math.distributions.Uniform' lower="0." upper="1000."/>
</distribution>
<distribution id='reproductiveNumber_Prior' x="@reproductiveNumber" spec='beast.math.distributions.Prior'>
<distr spec='beast.math.distributions.LogNormalDistributionModel' M="0" S="1.25"/>
</distribution>
<distribution id='becomeUninfectiousRate_Prior' x="@becomeUninfectiousRate" spec='beast.math.distributions.Prior'>
<distr spec='beast.math.distributions.Uniform' lower="0." upper="100."/>
</distribution>
</distribution>
<distribution id="jointTreeLikelihood" spec="util.CompoundDistribution">
<distribution data="@alignment" id="treeLikelihood" spec="TreeLikelihood" tree="@tree" siteModel="@SiteModel" branchRateModel="@StrictClock"/>
</distribution>
</distribution>
<RPNcalculator spec="beast.math.statistic.RPNcalculator" id="birth" expression="reproductiveNumber becomeUninfectiousRate *"> <!-- s/(d+s) -->
<parameter idref="becomeUninfectiousRate"/>
<parameter idref="reproductiveNumber"/>
</RPNcalculator>
<RPNcalculator spec="beast.math.statistic.RPNcalculator" id="sampling" expression="becomeUninfectiousRate samplingProportion *">
<parameter idref="becomeUninfectiousRate"/>
<parameter idref="samplingProportion"/>
</RPNcalculator>
<RPNcalculator spec="beast.math.statistic.RPNcalculator" id="death" expression="becomeUninfectiousRate 1 samplingProportion - *"> <!-- b*S0/(d+s) -->
<parameter idref="becomeUninfectiousRate"/>
<parameter idref="samplingProportion"/>
</RPNcalculator>
<run chainLength="200000000" id="mcmc" spec="MCMC" storeEvery="1000" distribution="@posterior">
<state id="state" storeEvery="100000">
<stateNode idref='tree'/>
<stateNode idref='origin'/>
<stateNode idref='becomeUninfectiousRate'/>
<stateNode idref='rho'/>
<stateNode idref='reproductiveNumber'/>
<stateNode idref="clock.rate"/>
<stateNode idref="freqParameter"/>
<stateNode idref="gammaShape"/>
<parameter dimension="1" id="rateAC" lower="0.0" upper="100.0" name="stateNode" value="1.0"/>
<parameter dimension="1" id="rateGT" lower="0.0" upper="100.0" name="stateNode" value="1.0"/>
<parameter dimension="1" id="rateAT" lower="0.0" upper="100.0" name="stateNode" value="1.0"/>
<parameter dimension="1" id="rateCG" lower="0.0" upper="100.0" name="stateNode" value="1.0"/>
<parameter dimension="1" id="rateCT" lower="0.0" upper="100.0" name="stateNode" value="1.0"/>
<parameter dimension="1" id="proportionInvariant" name="stateNode" value="0.1"/>
</state>
<!-- parameter weights for RealParameters roughly equal to parameter dimension -->
<operator id='becomeUninfectiousRate_scaler' spec='ScaleOperator' scaleFactor=".75" weight="10" parameter="@becomeUninfectiousRate"/>
<operator id='rho_scaler' spec='ScaleOperator' scaleFactor=".75" weight="1" parameter="@rho"/>
<operator id='reproductiveNumber_scaler' spec='ScaleOperator' scaleFactor=".75" weight="10" parameter="@reproductiveNumber"/>
<operator id="updown" spec="UpDownOperator" scaleFactor=".75" weight="10">
<up idref="reproductiveNumber"/>
<down idref="becomeUninfectiousRate"/>
</operator>
<operator id='orig_scaler' spec='ScaleOperator' scaleFactor=".75" weight="1" parameter="@origin"/>
<operator id="tree_updown" spec="UpDownOperator" scaleFactor=".75" weight="10">
<up idref="tree"/>
<down idref="clock.rate"/>
</operator>
<operator id='clock.rate_Scaler' spec='ScaleOperator' scaleFactor=".75" weight="1" parameter="@clock.rate" />
<operator id='treeScaler_root' spec='ScaleOperator' scaleFactor=".75" weight="1" tree="@tree" degreesOfFreedom="1" scaleAllIndependently="false" rootOnly='true'/>
<operator id='treeScaler' spec='ScaleOperator' scaleFactor=".75" weight="20" tree="@tree"/>
<operator spec='Uniform' weight="40" tree="@tree"/>
<operator spec='SubtreeSlide' weight="20" gaussian="true" size="1." tree="@tree"/>
<operator id='narrow2' spec='Exchange' isNarrow='true' weight="10" tree="@tree"/>
<operator id='wide2' spec='Exchange' isNarrow='false' weight="10" tree="@tree"/>
<operator spec='WilsonBalding' weight="10" tree="@tree"/>
<operator spec='ScaleOperator' scaleFactor=".75" weight=".2" parameter="@rateAC"/>
<operator spec='ScaleOperator' scaleFactor=".75" weight=".2" parameter="@rateAT"/>
<operator spec='ScaleOperator' scaleFactor=".75" weight=".2" parameter="@rateCG"/>
<operator spec='ScaleOperator' scaleFactor=".75" weight=".2" parameter="@rateCT"/>
<operator spec='ScaleOperator' scaleFactor=".75" weight=".2" parameter="@rateGT"/>
<operator spec='ScaleOperator' scaleFactor=".75" weight=".2" parameter="@proportionInvariant"/>
<operator id='gammaShapeScaler' spec='ScaleOperator' scaleFactor=".75" weight=".2" parameter="@gammaShape"/>
<operator autoOptimize="true" delta="0.2" id="FrequenciesExchanger" integer="false" spec="DeltaExchangeOperator" weight="0.1" parameter="@freqParameter"/>
<logger fileName="BDSKY_contemp_$(seed).log" id="tiplog" logEvery="1000" mode="autodetect" model="@posterior">
<distribution idref="posterior" name="log"/>
<log idref="BDlikelihood"/>
<log idref="jointTreeLikelihood"/>
<log id="TreeHeight" spec="beast.evolution.tree.TreeHeightLogger" tree="@tree"/>
<log idref="origin"/>
<log idref='rho'/>
<log idref="gammaShape"/>
<log idref="freqParameter"/>
<log idref="rateAC"/>
<log idref="rateAG"/>
<log idref="rateAT"/>
<log idref="rateCG"/>
<log idref="rateCT"/>
<log idref="rateGT"/>
<log idref="proportionInvariant"/>
<log idref='reproductiveNumber'/>
<log idref="becomeUninfectiousRate"/>
<log idref="birth"/>
<log idref="death"/>
<log idref="sampling"/>
</logger>
<logger id="screenlog" logEvery="10000" mode="autodetect">
<distribution idref="posterior" name="log"/>
<log arg="@posterior" id="ESS.0" spec="util.ESS"/>
<log idref="BDlikelihood"/>
<log idref="jointTreeLikelihood"/>
</logger>
<logger fileName="BDSKY_sequential_$(seed).trees" id="treelog" logEvery="10000" mode="tree">
<log spec='beast.evolution.tree.TreeWithMetaDataLogger' tree='@tree'>
<metadata idref="posterior"/>
<branchratemodel idref='StrictClock'/>
</log>
</logger>
</run>
</beast>
You can’t perform that action at this time.