calibrations | R Documentation |
Density, distribution, and quantile functions for calibrations used in MCMCtree.
dL(x, tL, p = 0.1, c = 1, pL = 0.025)
pL(q, tL, p = 0.1, c = 1, pL = 0.025)
qL(prob, tL, p = 0.1, c = 1, pL = 0.025)
dB(x, tL, tU, pL = 0.025, pU = 0.025)
dU(x, tU, pU = 0.025)
x |
numeric, vector of quantiles |
tL |
numeric, minimum age |
p |
numeric, mode parameter for truncated Cauchy |
c |
numeric, tail decay parameter for truncated Cauchy |
pL |
numeric, minimum probability bound |
q |
numeric, quantile |
prob |
numeric probability |
tU |
numeric, maximum age |
pU |
numeric, maximum probability bound |
Calculates the density, distribution and quantile functions for the minimum (dL) calibration, and the density function for the joint (dB) and maximum (dU) calibration bounds as implemented in MCMCtree. See Yang and Rannala (2007) and Inoue et al. (2010) for details.
A vector of density, probability, or quantile values as appropriate.
Mario dos Reis
Yang and Rannala. (2006) Bayesian Estimation of Species Divergence Times Under a Molecular Clock Using Multiple Fossil Calibrations with Soft Bounds. Mol. Biol. Evol., 23: 212–226.
Inoue, Donoghue and Yang (2010) The Impact of the Representation of Fossil Calibrations on Bayesian Estimation of Species Divergence Times. Syst. Biol., 59: 74–89.
# Plot a minimum bound calibration density:
curve(dL(x, 1), from=0, to=10, n=5e2)
# Plot a joint bounds calibration density:
curve(dB(x, 1, 6), from=0, to=10, n=5e2)
# Plot a maximum bound calibration density:
curve(dU(x, 6), from=0, to=10, n=5e2)
# Probability and quantile function for minimum bound (or truncated-Cauchy):
qv <- 0:20
# calculate probability vector from quantiles:
pv <- pL(qv, tL=1)
# calculate quantiles back from probability vector:
# (note numerical error)
qL(pv, tL=1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.