This generates the csv file that is used for input to Bacon. Will be run in interactive mode if necessary parameters aren't specified. Most users will want to use runBacon for their bacon needs.

writeBacon(
  L,
  bacon.dir = NA,
  chron.num = 1,
  remove.rejected = TRUE,
  overwrite = TRUE,
  cc = NA,
  site.name = L$dataSetName,
  model.num = NA,
  use.marine = NULL,
  ask.reservoir = TRUE,
  ...
)

Arguments

L

a LiPD object

bacon.dir

the directory where Bacon is installed on this computer.

chron.num

the number of the chronData object that you'll be working in

remove.rejected

don't write out dates that are marked as rejected

overwrite

overwrite files and directories

cc

An integer, or vector of integers corresponding to age that describes the calibration curve. You can specify here (see below) or if it's NA the code will guess based on archiveType

  • cc=1 IntCal20

  • cc=2 MarineCal20

  • cc=3 SHCal20

site.name

the name used for the bacon model (and directories)

model.num

chron.numModel do you want to use?

use.marine

use the marine 13C curve? (yes or no, or NULL to choose)

ask.reservoir

ask about reservoir corrections

...

Arguments passed on to selectData

var.name

string name of the variable to extract

paleo.or.chron

"paleoData" or "chronData"

paleo.or.chron.num

an integer that corresponds to paleo.num or chron Data object (L$<paleo.or.chron>[[?]]) has the variable you want?

meas.table.num

an integer that corresponds to paleo.num measurementTable has the variable you want?

table.type

What type of table do you want to select data from? ("measurement", "summary" or "ensemble")

always.choose

Force selection of the variable from a list

alt.names

A vector of strings for alternative names to search for

ens.table.num

an integer that corresponds to ensembleTable you want to get the variable from?

sum.table.num

an integer that corresponds to which summaryTable you want to get the variable from?

strict.search

Use a strict.search to look for the ageEnsemble and depth variables. TRUE(default) or FALSE.

Value

L the input LiPD file with methods added to the chronModel.

See also

Author

Nick McKay

Examples

if (FALSE) { # \dontrun{
writeBacon(L)
#Run in interactive mode

writeBacon(L,chron.num=1,meas.table.num = 1,bacon.dir="~/Bacon/",remove.rejected=TRUE,overwrite=TRUE,cc=NA,site.name=L$dataSetName,model.num=NA)
} # }