Title: | Bayesian Age-Depth Modelling of Cores Dated by Pb-210 |
---|---|
Description: | An approach to age-depth modelling that uses Bayesian statistics to reconstruct accumulation histories for 210Pb-dated deposits using prior information. It can combine 210Pb, radiocarbon, and other dates in the chronologies. See Aquino et al. (2018) <doi:10.1007/s13253-018-0328-7>. Note that parts of the code underlying 'rplum' are derived from the 'rbacon' package by the same authors, and there remains a degree of overlap between the two packages. |
Authors: | Maarten Blaauw [aut, cre] , J. Andres Christen [aut, ctb, cph] , Marco A. Aquino Lopez [aut] , Judith Esquivel Vazquez [ctb], Oscar M. Gonzalez V. [ctb], Ted Belding [cph], James Theiler [cph], Brian Gough [cph], Charles Karney [cph] |
Maintainer: | Maarten Blaauw <[email protected]> |
License: | GPL (>= 2) |
Version: | 0.5.1 |
Built: | 2024-10-29 06:02:54 UTC |
Source: | https://github.com/maarten14c/rplum |
This is the main age-depth modelling function of the rplum package for 210Pb age-modelling.
Plum( core = "HP1C", thick = 1, otherdates = NA, coredir = "", phi.shape = 2, phi.mean = 50, s.shape = 5, s.mean = 10, Al = 0.1, date.sample = c(), n.supp = c(), remove.tail = TRUE, ra.case = c(), Bqkg = TRUE, seed = NA, prob = 0.95, d.min = 0, d.max = NA, d.by = 1, depths.file = FALSE, depths = c(), depth.unit = "cm", age.unit = "yr", unit = depth.unit, acc.shape = 1.5, acc.mean = 10, mem.strength = 10, mem.mean = 0.5, boundary = NA, hiatus.depths = NA, hiatus.max = 10000, add = c(), after = 1e-04/thick, cc = 1, cc1 = "IntCal20", cc2 = "Marine20", cc3 = "SHCal20", cc4 = "ConstCal", cc.dir = "", postbomb = 0, delta.R = 0, delta.STD = 0, t.a = 3, t.b = 4, normal = FALSE, suggest = TRUE, reswarn = c(10, 200), remember = TRUE, ask = TRUE, run = TRUE, defaults = "defaultPlum_settings.txt", sep = ",", dec = ".", runname = "", slump = c(), BCAD = FALSE, ssize = 4000, th0 = c(), burnin = min(500, ssize), MinAge = c(), youngest.age = c(), MaxAge = c(), oldest.age = c(), cutoff = 0.001, rounded = 1, plot.pdf = TRUE, dark = 1, date.res = 100, age.res = 200, close.connections = TRUE, save.info = TRUE, older.than = c(), younger.than = c(), save.elbowages = FALSE, verbose = TRUE, ... )
Plum( core = "HP1C", thick = 1, otherdates = NA, coredir = "", phi.shape = 2, phi.mean = 50, s.shape = 5, s.mean = 10, Al = 0.1, date.sample = c(), n.supp = c(), remove.tail = TRUE, ra.case = c(), Bqkg = TRUE, seed = NA, prob = 0.95, d.min = 0, d.max = NA, d.by = 1, depths.file = FALSE, depths = c(), depth.unit = "cm", age.unit = "yr", unit = depth.unit, acc.shape = 1.5, acc.mean = 10, mem.strength = 10, mem.mean = 0.5, boundary = NA, hiatus.depths = NA, hiatus.max = 10000, add = c(), after = 1e-04/thick, cc = 1, cc1 = "IntCal20", cc2 = "Marine20", cc3 = "SHCal20", cc4 = "ConstCal", cc.dir = "", postbomb = 0, delta.R = 0, delta.STD = 0, t.a = 3, t.b = 4, normal = FALSE, suggest = TRUE, reswarn = c(10, 200), remember = TRUE, ask = TRUE, run = TRUE, defaults = "defaultPlum_settings.txt", sep = ",", dec = ".", runname = "", slump = c(), BCAD = FALSE, ssize = 4000, th0 = c(), burnin = min(500, ssize), MinAge = c(), youngest.age = c(), MaxAge = c(), oldest.age = c(), cutoff = 0.001, rounded = 1, plot.pdf = TRUE, dark = 1, date.res = 100, age.res = 200, close.connections = TRUE, save.info = TRUE, older.than = c(), younger.than = c(), save.elbowages = FALSE, verbose = TRUE, ... )
core |
Name of the core, given using quotes. Defaults to one of the cores provided with rplum, |
thick |
Plum will divide the core into sections of equal thickness specified by thick (default |
otherdates |
Name of (optional) file with radiocarbon dates. This file should have the same format as the one used for rbacon. For example, |
coredir |
Folder where the core's files |
phi.shape |
Shape parameter of the prior gamma distribution used for the influx of Pb-210 to the sediment, default |
phi.mean |
Mean parameter of the prior gamma distribution used for the influx of Pb-210 to the sediment, default |
s.shape |
Shape parameter of the prior gamma distribution used for the supported Pb-210 to the sediment, default |
s.mean |
Mean parameter of the prior gamma distribution used for the supported Pb-210 to the sediment, default |
Al |
Parameter used to limit the chronologies described in Aquino-Lopez et al. (2018) for the minimum distinguishable unsupported activity; default |
date.sample |
Date (in calendar years, e.g., AD 2023) at which the core was measured for Pb-120. This date will be used as a surface date and is assumed to have no uncertainty. If the date is not provided (in the .csv file or as |
n.supp |
This value will delete n.supp data points from the deepest part of the core, and these points will then be used exclusively to estimate the supported activity. If this option is used, a constant supported Pb-210 will be assumed, |
remove.tail |
Whether or not to remove the tail measurements when plotting. Sometimes automated removal might go wrong, or additional dates exist further down, so then this option can be used to avoid removing the tail 210Pb measurements. Is set to FALSE if there are non-210Pb data further down the core. |
ra.case |
How to use radium-226 measurements if they are provided in the core's .csv file. 1 = assume constant radium, 2 = assume varying radium and use the radium measurements as individual estimates of supported Pb-210. If no radium measurements are present, use |
Bqkg |
This variable indicates whether total Pb-210 is expressed in Bq/kg (default; |
seed |
Seed used for C++ executions; if it is not assigned then the seed is set by system. Default |
prob |
Confidence interval to report. This should lie between 0 and 1, default |
d.min |
Minimum depth of age-depth model (use this to extrapolate to depths higher than the top dated depth). |
d.max |
Maximum depth of age-depth model (use this to extrapolate to depths below the bottom dated depth). |
d.by |
Depth intervals at which ages are calculated. Defaults to |
depths.file |
By default, Plum will calculate the ages for the depths |
depths |
By default, Plum will calculate the ages for the depths |
depth.unit |
Units of the depths. Defaults to |
age.unit |
Units of the ages. Defaults to |
unit |
Deprecated and replaced by |
acc.shape |
The prior for the accumulation rate consists of a gamma distribution with two parameters.
Its shape is set by acc.shape (default |
acc.mean |
The accumulation rate prior consists of a gamma distribution with two parameters. Its mean is set by acc.mean (default |
mem.strength |
The prior for the memory (dependence of accumulation rate between neighbouring depths) is a beta distribution, which looks much like the gamma distribution.
but its values are always between 0 (no assumed memory) and 1 (100% memory). Its default settings of |
mem.mean |
The prior for the memory is a beta distribution, which looks much like the gamma distribution but
its values are always between 0 (no assumed memory) and 1 (100% memory). Its default settings of |
boundary |
The assumed depths of any boundary, which divides sections of different accumulation rate regimes (e.g., as indicated by major change in the stratigraphy). No hiatus is assumed between these sections, and memory is reset crossing the boundary. Different accumulation priors can be set for the sections above and below the boundary, e.g., |
hiatus.depths |
The assumed depths for any hiatus should be provided as, e.g.,
|
hiatus.max |
The prior for the maximum length of the hiatus. Hiatus length is a uniform distribution, with equal probabilities between 0 and |
add |
Add a value to the maximum hiatus length if a boundary is chosen. Defaults to 100 yr (or whatever other age unit is chosen). Can be adapted if Plum complains that the parameters are out of support. |
after |
Sets a short section above and below hiatus.depths within which to calculate ages. For internal calculations - do not change. |
cc |
Calibration curve for C-14 dates: |
cc1 |
For northern hemisphere terrestrial 14C dates (IntCal20). |
cc2 |
For marine 14C dates (Marine20). |
cc3 |
For southern hemisphere 14C dates (SHCal20). |
cc4 |
Use an alternative curve (3 columns: cal BP, 14C age, error, separated by white spaces and saved as a plain-text file). See |
cc.dir |
Directory where the calibration curves for C14 dates |
postbomb |
Use a postbomb curve for negative (i.e. postbomb) 14C ages. |
delta.R |
Mean of core-wide age offsets (e.g., regional marine offsets). |
delta.STD |
Error of core-wide age offsets (e.g., regional marine offsets). |
t.a |
The dates are treated using the t distribution by default ( |
t.b |
The dates are treated using the t distribution by default ( |
normal |
By default, Plum uses the t-distribution to treat the dates. Use |
suggest |
If initial analysis of the data indicates abnormally slow or fast accumulation rates, Plum will suggest to change the prior.
Also, if the length of the core would cause too few or too many sections with the default settings, Plum will suggest an alternative section thickness |
reswarn |
Plum will warn you if the number of sections lies outside the safe range (default between 10 and 200 sections;
|
remember |
Plum will try to remember which settings you have applied to your cores (default |
ask |
By default Plum will ask you to confirm that you want to run the core with the provided settings. Disable this using |
run |
In order to load an existing Plum run instead of producing a new one, you can use |
defaults |
Name of the file containing settings for the core. For internal use only - do not change. |
sep |
Separator between the fields of the plain text file containing the dating information. Default |
dec |
Character for decimal points. Default to |
runname |
Text to add to the corename for specific runs, e.g., |
slump |
Upper and lower depths of any sections of assumed abrupt accumulation, that require excising before age-modelling (and adding after age-modelling). Requires pairs of depths, e.g., |
BCAD |
The calendar scale of graphs and age output-files is in cal BP (calendar or calibrated years before the present, where the present is AD 1950) by default, but can be changed to BC/AD using |
ssize |
The approximate amount of iterations to store at the end of the MCMC run. Default 2000; decrease for faster (but less reliable) runs or increase for cores where the MCMC mixing (panel at upper-left corner of age-model graph) appears problematic. |
th0 |
Starting years for the MCMC iterations. |
burnin |
Amount of initial, likely sub-optimal MCMC iterations that will be removed. |
MinAge |
Deprecated - use youngest.age instead. |
youngest.age |
Minimum age limit for Bacon runs, default at current year in cal BP. To set plot limits, use |
MaxAge |
Deprecated - use oldest.age instead. |
oldest.age |
Maximum age limit for Bacon runs, default at 1,000,000 cal BP. To set plot limits, use |
cutoff |
Avoid plotting very low probabilities of date distributions (default |
rounded |
Rounding of calendar years. Defaults to 1 decimal. |
plot.pdf |
Produce a pdf file of the age-depth plot. Defaults to |
dark |
Darkness of the greyscale age-depth model. The darkest grey value is |
date.res |
Date distributions are plotted using |
age.res |
Resolution or amount of greyscale pixels to cover the age scale of the age-model plot. Default |
close.connections |
Internal option to close connections after a run. Default |
save.info |
By default, a variable called ‘info’ with relevant information about the run (e.g., core name, priors, settings, ages, output) is saved into the working directory. Note that this will overwrite any existing variable with the same name - as an alternative, one could run, e.g., |
older.than |
an option to enable dates at the limit of C-14 dating. If there are older.than dates (works only for non-210Pb data), they tell us that the core should be older than a certain age at that depth. For example, if the 7th and 8th dates in the core's 'otherdates' .csv file are older-than dates, use as |
younger.than |
an option to provide younger-than ages, for example a historical pollen marker. If there are younger-than dates (works only for non-210Pb data), they tell us that the core should be younger than a certain age at that depth. For example, if the 7th and 8th dates in the core's 'otherdates' .csv file are younger.than dates, use as |
save.elbowages |
If you want to have a file with the MCMC-derived ages for all the age-depth model's elbows, set |
verbose |
Provide feedback on what is happening (default |
... |
options for the age-depth graph. See the agedepth and calib.plot functions. |
Plum is an approach to age-depth modelling that uses Bayesian statistics in order to reconstruct accumulation histories for 210Pb-dated deposits by taking into account prior information, and can combine 210Pb, radiocarbon and other dates (Aquino et al. 2018).
Plum handles 210Pb and other dated depths within in a core, by dividing a core into many thin vertical sections (by default of thick=1
cm thickness),
and through millions of Markov Chain Monte Carlo (MCMC) iterations estimates the flux of 210Pb and supported 210Pb, as well as
the accumulation rate (in years/cm; so more correctly, sedimentation times) for each of these sections.
Combined with an estimated starting date for the first section, these accumulation rates and values for 210Pb then form the age-depth and 210Pb model.
The accumulation rates are constrained by prior information on the accumulation rate (acc.mean, acc.shape)
and its
variability between neighbouring depths, or "memory" (mem.mean, mem.strength
). Hiatuses can be introduced as well,
also constrained by prior information (hiatus.max
). The 210Pb flux (phi) and supported 210Pb (s) are constrained by priors phi.mean, phi.shape, s.mean and s.shape
.
Although Plum was developed for 210Pb dates, it can also include absolute dates (e.g., 14C, OSL, tephra or other dates on a calendar scale).
Radiocarbon dates should be calibrated using either IntCal20
(for terrestrial northern hemisphere material; Reimer et al., 2020), Marine20 (for marine dates; Hughen et al., 2020),
SHCal20 (for southern hemisphere dates; Hogg et al., 2020) or any other calibration curve (see below), while modern 14C
dates are calibrated using one of the post-bomb calibration curves (NH1, NH2 or NH3 for the northern hemisphere,
SH1-2 or SH3 for the southern hemisphere; Hua et al., 2022). See http://calib.org/CALIBomb/ if you are unsure which
postbomb curve you need. If Plum finds postbomb dates (negative 14C ages) and you haven't specified a postbomb curve,
you will be prompted. Provide postbomb curves as, e.g., postbomb=1
for the NH1 postbomb curve (2 for NH2, 3 for NH3,
4 for SH1-2, 5 for SH3).
For calendar dates, i.e. dates that are already on the calendar scale and thus should not be calibrated, setcc=0
.
Plum also needs the date of sampling, in AD (date.sample
).
rplum works by calling the rbacon package. Since version 3.1.0, Bacon can also handle younger-than and older-than ages, with the model aiming to either go 'above' or 'below' such dates as requested. If the resulting combination of parameters becomes problematic (e.g., no initial combination of parameters can be found that obeys the priors or is in chronological order), then the output will often be wrong. If so, using the function set.initvals could help.
By default, the initial MCMC values of the Bacon age-depth model (upper ages and accumulation rate for each model section) are estimated randomly. Since version 3.1.0, these starting values can also be provided in a file with extension _bacon.init, placed within the core's folder. This file will need to have two rows, each for one of the two initial sets of parameters required (the t-walk requires two starting estimates for all MCMC parameters). If such a file is found (and correctly formatted), Bacon will use the values within this file as starting points for the MCMC run. See function set.initvals for more information.
An age-depth model graph, its age estimates, a summary, and the info variable which contains all relevant information.
Maarten Blaauw, J. Andres Christen, Marco A. Aquino L.
Aquino-Lopez, M.A., Blaauw, M., Christen, J.A., Sanderson, N., 2018. Bayesian analysis of 210Pb dating. Journal of Agricultural, Biological, and Environmental Statistics 23, 317-333.
Blaauw, M. and Christen, J.A., 2011. Flexible paleoclimate age-depth models using an autoregressive gamma process. Bayesian Analysis 6, 457-474.
Christen, J.A., Perez E.S., 2010. A new robust statistical model for radiocarbon data. Radiocarbon 51, 1047-1059.
Hogg et al., 2020. SHCal20 Southern Hemisphere calibration, 0-55,000 years cal BP. Radiocarbon 62, 759-778.
Hua et al., 2022. Atmospheric radiocarbon for the period 1950-2019. Radiocarbon 64(4), 723-745, doi:10.1017/RDC.2021.95
Hughen et al., 2020. Marine20-the marine radiocarbon age calibration curve (0-55,000 cal BP). Radiocarbon 62, 779-820.
Jones, V.J., Stevenson, A.C., Battarbee, R.W., 1989. Acidification of lakes in Galloway, south west Scotland - a diatom and pollen study of the post-glacial history of the Round Loch of Glenhead. Journal of Ecology 77, 1-23.
Reimer et al., 2020. The IntCal20 Northern Hemisphere radiocarbon age calibration curve (0–55 cal kBP). Radiocarbon 62, 725-757.
Plum(ask=FALSE, ssize=1000, coredir=tempfile(), date.sample=2018.5, ra.case=0, n.supp=3)
Plum(ask=FALSE, ssize=1000, coredir=tempfile(), date.sample=2018.5, ra.case=0, n.supp=3)
Lists all folders located within the core's directory.
Plum_runs(coredir = get("info")$coredir)
Plum_runs(coredir = get("info")$coredir)
coredir |
The directory where the Bacon runs reside. Defaults to |
The directory is either "Plum_runs", "Cores" or a custom-named one.
A list of folders
Maarten Blaauw, J. Andres Christen
Remove files .bacon, .out, .pdf, _ages.txt, and _settings.txt of current core.
Plum.cleanup(set = get("info"))
Plum.cleanup(set = get("info"))
set |
Detailed information of the current run, stored within this session's memory as variable |
If cores behave badly, you can try cleaning up previous runs and settings, by removing files .bacon, .out, .pdf, _ages.txt, and _settings.txt of current core.
A message stating that the files and settings of this run have been deleted.
Maarten Blaauw, J. Andres Christen