Description Usage Arguments Value Note
This function uses the case network from the spatial simulator simulators and produces a set of dated tip sequences. The distribution and number of tips are declared as variables, with the default case choosing 1 extant tip from each clade. The effect of this being to make the easiest generation of the correct TMRCA by BEAST, with the least amount of computatonal demand.
1 2 3 |
case.tree |
the case tree generated from a simulator function within sims4 |
file |
the path name where the nexus file of samples is to be save to |
n.tips |
the numer of tips to chosen in total |
all.clades |
boolean determining if all extant clades have to be sampled. Default = TRUE |
prop.clades |
if all.clades==FALSE, prop.clades specifies the proportion of clades to be sampled |
extant |
boolean determining if only extant tips are chosen. Default = TRUE. An extant tip is simply a case that was yet to be chosen to be a parent or not at the end of the simulation |
prop.times |
if extant = FALSE determines over what case network time window samples are to be chosen by. As such, prop.times can only take a value between 0 and 1, whereby 1 would mean all cases could be sampled at random, and 0.5 would mean only the most recent half of the cases could be sampled. An error will throw if prop.times*length(case.tree$ID)<n.tips, i.e. more tips than possible given sampling time window. |
a nexus file of dated tips with sequences
If the combination of prop.times and extant==FALSE creates a time window that does not include all clades, and all.clades == TRUE, only all the possible clades within the time window will be sampled.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.