CalibrateAge: Calibrate 14C age with Bchron

Description Usage Arguments Details Value See Also Examples

View source: R/CalibrateAge.R

Description

Calibrates a set of 14C ages in a dataframe using the BChron package

Usage

1
2
3
4
5
6
7
8
CalibrateAge(
  df,
  age.14C = "age.14C",
  age.14C.se = "age.14C.se",
  curve = "intcal20",
  return.type = "df",
  offset = NULL
)

Arguments

df

dataframe

age.14C

Name of column with 14C ages, Default: 'age.14C'

age.14C.se

Name of column with 1se 14C age uncertainty, Default: 'age.14C.se'

curve

Calibration curve, Default: 'intcal20'

return.type

Return the ammended dataframe or additionally the list of PDFs, Default: 'df'

offset

Optional offset applied to all 14C ages, Default: 0

Details

A wrapper for Bchron::Bchroncalibrate

Value

A dataframe or list

See Also

BchronCalibrate SummariseEmpiricalPDF

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
# With defaults
dat <- data.frame(age.14C = c(2000, 20000),
                  age.14C.se = c(100, 200))
CalibrateAge(dat)

# Change the calibration
CalibrateAge(dat, curve = "marine13")

# Return the PDFs
cal.lst <- CalibrateAge(dat, curve = "marine13", return = "lst")
with(cal.lst[[2]][[1]][[1]], {plot(ageGrid, densities)})

# Use different column names
dat <- data.frame(radiocarbon.age = c(2000, 20000),
                 se = c(100, 200))
CalibrateAge(dat, age.14C = "radiocarbon.age", age.14C.se = "se")
## Not run: 
if(interactive()){
 #EXAMPLE1
 }

## End(Not run)

EarthSystemDiagnostics/ecustools documentation built on Jan. 15, 2022, 5:22 p.m.