clean | R Documentation |
Given an observed radiocarbon age, remove the impact of contamination (for example, 1% contamination with modern carbon) to estimate the true/target age
clean(
y,
er = 0,
percentage,
percentage.error = 0,
F.contam = 1,
F.contam.er = 0,
MC = TRUE,
its = 10000,
roundby = 1,
decimals = 5,
visualise = TRUE,
talk = TRUE,
eq.x = 5,
eq.y = c(),
eq.size = 0.75,
true.col = "darkgreen",
observed.col = "blue",
contamination.col = "red",
true.pch = 20,
observed.pch = 18,
contamination.pch = 17,
true.name = "true",
xlab = "contamination (%)",
ylab = "F14C",
ylim = c(),
C14.axis = TRUE,
bty = "u"
)
y |
The observed radiocarbon age |
er |
The error of the observed radiocarbon age |
percentage |
Relative amount of contamination. Must be between 0 and 100 (%) |
percentage.error |
Uncertainty of the contamination. Assumed to be normally distributed (which fails close to 0% or 100% contamination levels). Defaults to 0%. |
F.contam |
The F14C of the contamination. Set at 1 for carbon of modern radiocarbon age, at 0 for 14C-free carbon, or anywhere inbetween. |
F.contam.er |
The error of the contamination. Defaults to 0. |
MC |
Whether or not to use Monte Carlo iterations to estimate the values. Defaults to TRUE, because it treats uncertainties better than if set to FALSE. |
its |
Amount of iterations to use if MC=TRUE. Defaults to 10,000. |
roundby |
Rounding of the output for C14 ages. Defaults to 1 decimal. |
decimals |
Rounding of the output. Since details matter here, the default is to provide 5 decimals. |
visualise |
By default, a plot is made to visualise the target and observed F14C values, together with the inferred contamination. |
talk |
Whether or not to report the calculations made. Defaults to |
eq.x |
Leftmost location of the equation. Defaults to |
eq.y |
Vertical location of the equation. Defaults to the top of the graph. |
eq.size |
Size of the font of the equation. In case the equation gets jumbled up upon resizing of a graphical device, just issue the previous 'clean' command again. Defaults to |
true.col |
Colour for the target/true values. Defaults to "darkgreen". |
observed.col |
Colour for the observed values. Defaults to blue. |
contamination.col |
Colour for the contamination values. Defaults to red. |
true.pch |
Icon for the true/target date. Defaults to a filled circle. |
observed.pch |
Icon for the observed. Defaults to a diamond |
contamination.pch |
Icon for the contamination. Defaults to a triangle. |
true.name |
Name of the label of the true/target date |
xlab |
Name of the x-axis. Defaults to 'contamination (%)'. |
ylab |
Name of the y-axis. Defaults to 'F14C'. |
ylim |
Limits of the y-axis. Calculated automatically by default. |
C14.axis |
Whether or not to draw a secondary vertical axis for C14 ages. Defaults to |
bty |
Draw a box around a box of a certain shape. Defaults to |
Whereas the function takes C14 ages and percentage contamination as input, internal calculations are done in the F14C realm and using fractions (between 0 and 1). The central calculation is 'F_true = ((1-frac)*F_obs) - (frac*F_contam)', where 'F_true' is the true or target age in F14C, 'frac' is the fraction of contamination, 'F_obs' is the F14C of the observed C14 age, and 'F_contam' is the F activity of the contamination. In some extreme cases, the calculations will spit out unexpected results. Messages will be provided in most of these cases.
The true/target radiocarbon age and error
Maarten Blaauw
# 1% contamination with modern carbon (no uncertainties in contamination's percentage or F)
clean(5000, 20, 1, 0, 1, 0)
# now with errors:
clean(5000, 20, 1, 0.1, 1, 0.1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.