flux.age.ghost: Plot flux rates for proxies.

View source: R/accrate.R

flux.age.ghostR Documentation

Plot flux rates for proxies.

Description

Plot grey-scale representation of estimated flux rates for proxies against calendar age.

Usage

flux.age.ghost(
  proxy = 1,
  age.lim = c(),
  yr.lim = age.lim,
  age.res = 200,
  yr.res = age.res,
  set = get("info"),
  flux = c(),
  plot.range = TRUE,
  prob = 0.8,
  range.col = grey(0.5),
  range.lty = 2,
  plot.mean = TRUE,
  mean.col = "red",
  mean.lty = 2,
  plot.median = TRUE,
  median.col = "blue",
  median.lty = 2,
  flux.lim = c(),
  flux.lab = expression("flux (g cm"^-1 * " yr"^-1 * ")"),
  upper = 0.95,
  rgb.scale = c(0, 0, 0),
  rgb.res = 100,
  dark = set$dark,
  cutoff = 0.001,
  BCAD = set$BCAD,
  age.lab = c(),
  yr.lab = age.lab,
  rotate.axes = FALSE,
  rev.flux = FALSE,
  rev.age = FALSE,
  rev.yr = rev.age
)

Arguments

proxy

Which proxy to use (counting from the column number in the .csv file after the depths column).

age.lim

Minimum and maximum calendar age ranges, calculated automatically by default (age.lim=c()).

yr.lim

Deprecated - use age.lim instead

age.res

Resolution or amount of greyscale pixels to cover the age scale of the plot. Default age.res=200.

yr.res

Deprecated - use age.res instead

set

Detailed information of the current run, stored within this session's memory as variable info.

flux

Define a flux variable within the R session (consisting of depths and their proxy concentrations in two columns) and provide the name of this variable, e.g.: flux.age.ghost(flux=flux1). If left empty (flux=c()), a flux file is expected (see proxy).

plot.range

Plot curves that indicate a probability range, at resolution of yr.res.

prob

Probability range, defaults to prob=0.8 (10 % at each side).

range.col

Red seems nice.

range.lty

Line type of the confidence ranges.

plot.mean

Plot the mean fluxes.

mean.col

Red seems nice.

mean.lty

Line type of the means.

plot.median

Plot the median fluxes.

median.col

Blue seems nice.

median.lty

Line type of the medians.

flux.lim

Limits of the flux axes.

flux.lab

Axis labels. Defaults to flux.lab="flux".

upper

Maximum flux rates to plot. Defaults to the upper 99%; upper=0.99.

rgb.scale

The function to produce a coloured representation of all age-models. Needs 3 values for the intensity of red, green and blue. Defaults to grey-scales: rgb.scale=c(0,0,0), but could also be, say, scales of red (rgb.scale=c(1,0,0)).

rgb.res

Resolution of the colour spectrum depicting the age-depth model. Default rgb.res=100.

dark

The darkest grey value is dark=1 by default; lower values will result in lighter grey but values >1 are not allowed.

cutoff

Point below which colours will no longer be printed. Default cutoff=0.001.

BCAD

The calendar scale of graphs and age output-files is in cal BP by default, but can be changed to BC/AD using BCAD=TRUE.

age.lab

The labels for the calendar axis (default age.lab="cal BP" or "BC/AD" if BCAD=TRUE).

yr.lab

Deprecated - use age.lab instead

rotate.axes

The default of plotting calendar year on the horizontal axis and fluxes on the vertical one can be changed with rotate.axes=TRUE.

rev.flux

The flux axis can be reversed with rev.flux=TRUE.

rev.age

The direction of the age axis can be reversed using rev.age=TRUE.

rev.yr

Deprecated - use rev.age instead

Details

To plot flux rates (e.g. pollen grains/cm2/yr) as greyscales, provide a plain text file with headers and the data in columns separated by commas, ending in '_flux.csv' and saved in your core's folder. The first column should contain the depths, and the next columns should contain the proxy concentration values (leaving missing values empty). Then type for example flux.age.ghost(1) to plot the flux values for the first proxy in the .csv file. Instead of using a _flux.csv file, a flux variable can also be defined within the R session (consisting of depths and their proxy concentrations in two columns). Then provide the name of this variable, e.g.: flux.age.ghost(flux=flux1). See Bacon_runs/MSB2K/MSB2K_flux.csv for an example.

Value

A plot of flux rates.

Author(s)

Maarten Blaauw, J. Andres Christen

Examples

## Not run: 
  Bacon(run=FALSE, coredir=tempfile())
  agedepth(yr.res=50)
  flux.age.ghost(1)

## End(Not run)

rbacon documentation built on Sept. 30, 2024, 9:40 a.m.