Add individual calibrated dates to a plot.
draw.dates(
age,
error,
depth,
cc = 1,
postbomb = FALSE,
reservoir = c(),
calibt = c(),
prob = 0.95,
threshold = 0.001,
BCAD = FALSE,
ex = 0.9,
normalise = TRUE,
draw.hpd = TRUE,
hpd.lwd = 2,
hpd.col = rgb(0, 0, 1, 0.7),
mirror = TRUE,
up = FALSE,
on.axis = 1,
col = rgb(0, 0, 1, 0.3),
border = rgb(0, 0, 1, 0.5),
add = FALSE,
cal.lab = c(),
cal.lim = c(),
y.lab = c(),
y.lim = c(),
y.rev = TRUE,
labels = c(),
label.x = 1,
label.y = c(),
label.cex = 0.8,
label.col = border,
label.offset = c(0, 0),
label.adj = c(1, 0),
label.rot = 0,
ccdir = NULL,
...
)
Mean of the uncalibrated C-14 age (or multiple ages).
Error of the uncalibrated C-14 age (or ages).
Depth(s) of the date(s)
Calibration curve for C-14 dates (1, 2, 3, or 4, or, e.g., "IntCal20", "Marine20", "SHCal20", "nh1", "sh3", or "mixed"). If there are multiple dates but all use the same calibration curve, one value can be provided.
Whether or not this is a postbomb age. Defaults to FALSE.
Reservoir age, or reservoir age and age offset.
Calibration based on the student-t distribution. By default, the Gaussian distribution is used (calibt=FALSE
). To use the student-t distribution, provide two parameters such as calibt=c(3,4)
.
Probability confidence intervals (between 0 and 1).
Report only values above a threshold. Defaults to threshold=0.001
.
Use BC/AD or cal BP scale (default cal BP).
Exaggeration of the height of the distribution
If TRUE, the date is normalised by setting its peak value to 1 (handy for estimating how high to draw it). If there are multiple dates, it is normalised to the peak of the most precise date. Otherwise the peak of each date is at the same height.
Whether or not to draw the hpd ranges as a line
Width of the line of the hpd ranges
Colour of the hpd rectangle
Plot distributions mirrored, a bit like a swan. Confuses some people but looks nice to the author so is the default.
If mirror is set to FALSE, the distribution can be plotted up or down, depending on the direction of the axis.
Which axis to plot on. Defaults to 'x' or 1, but can be set to 'y' or 2.
Colour of the inside of the distribution
Colour of the border of the distribution
Whether or not to add the dates to an existing plot. If set to FALSE (default), a plot will be set up.
Title of the calendar axis (if present)
Limits of the calendar axis (if present)
Title of the vertical axis (if present)
Limits of the vertical axis (if present)
Reverse the y-axis. Defaults to TRUE
Add labels to the dates. Empty by default.
Horizontal position of the date labels. By default draws them before the youngest age (1), but can also draw them after the oldest age (2), or above its mean (3).
Vertical positions of the labels. Defaults to 0 (or 1 if label.x is 3 or 4).
Size of labels.
Colour of the labels. Defaults to the colour given to the borders of the dates.
Offsets of the positions of the labels, giving the x and y offsets. Defaults to c(0,0).
Justification of the labels. Follows R's adj option: A value of ‘0’ produces left-justified text, ‘0.5’ (the default) centered text and ‘1’ right-justified text.
Rotation of the label. 0 by default (horizontal).
Directory of the calibration curves. Defaults to where the package's files are stored (system.file), but can be set to, e.g., ccdir="curves"
.
Additional plotting options
plot(0, xlim=c(500,0), ylim=c(0, 2))
draw.dates(130, 20, depth=1)
Run the code above in your browser using DataLab