find_tracer_breakthrough: Calculate the breakthrough time of a tracer

Description Usage Arguments Value Examples

View source: R/fit_models.R

Description

The breakthrough time of a tracer in the drainage of a soil column is calculated as the maximum of curvature of its concentration in a suitable time interval.

Usage

1
2
3
4
5
6
7
8
9
find_tracer_breakthrough(
  tracer_data,
  time_interval,
  smooth = TRUE,
  loess_span = 0.2,
  xlab_tag = "Time (sec)",
  ylab_tag = expression(c/c[0]),
  do_plot = TRUE
)

Arguments

tracer_data

tibble or data.frame. Tracer breakthrough data. The first column must be time, the second the tracer concentration.

time_interval

numeric vector of length 2. The time interval to search for the breakthrough, typically early in the experiment.

smooth

logical. Should the tracer data be smoothed by loess first. Default is true.

loess_span

numeric. The smoothing parameter for the loess smoother. Default is 0.2.

xlab_tag

string or expression for the x label. Default is Time (sec).

ylab_tag

string or expression for the y label. Default is c/c0.

do_plot

logical. Should a plot be produced. Default is TRUE.

Value

list. breakthrough_time The estimated time of the tracer breakthrough.

tracer_data The original tracer data augmented by the smoothed data (is smooth = TRUE), first derivative of the tracer data (slope), calculated curvature and its first derivative

Examples

1
2
data(tracer)
find_tracer_breakthrough(tracer_data = tracer, time_interval = c(30000, 40000))

ChrisBogner/ViscousFlow documentation built on June 13, 2021, 7:47 a.m.