Description Usage Arguments Value Author(s) References Examples
View source: R/sample-phybreak.R
Function to take (additional) samples from the posterior distribution of a phylogenetic and transmission tree
(plus associated parameters), within a phybreak
-object.
1 2 | sample.phybreak(phybreak.object, nsample, thin = 1, keepphylo = NULL,
phylotopology_only = 0)
|
phybreak.object |
An object of class |
nsample |
The number of samples to take. |
thin |
The thinning to use (values after every |
keepphylo |
The proportion of tree updates keeping the phylotree intact. If there is more than one sample per host, keepphylo should be 0. If set to NULL (default), this is done automatically, otherwise it is set to 0.2. |
phylotopology_only |
The proportion of tree updates in which only the within-host minitree topology is sampled, and the transmission tree as well as coalescence times are kept unchanged. |
The phybreak
-object used to call the function, including (additional) samples from the posterior.
Don Klinkenberg don@xs4all.nl
Klinkenberg et al. (2017) Simultaneous inference of phylogenetic and transmission trees in infectious disease outbreaks. PLoS Comput Biol, 13(5): e1005495.
1 2 3 4 5 6 | #First create a phybreak-object
simulation <- sim.phybreak(obsize = 5)
MCMCstate <- phybreak(data = simulation)
MCMCstate <- burnin.phybreak(MCMCstate, ncycles = 20)
MCMCstate <- sample.phybreak(MCMCstate, nsample = 50, thin = 2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.