transPlot: Plots transport profiles of single run experiments

Description Usage Arguments Details Value Author(s) References Examples

View source: R/transPlot.R

Description

Given the transport complete information of the interest species and, optionally, secondary and tertiary species, the function plots transport profiles including (if given) non-linear regression models that can be obtained using transTrend.

Usage

1
2
3
4
5
transPlot(trans, trend = NULL, secondary = NULL, tertiary = NULL,
  sec.trend = "spline", lin.secon = FALSE, span = 0.75, legend = FALSE,
  xlab = "Time (h)", ylab = expression(Phi), xlim = NULL, ylim = NULL,
  xbreaks = NULL, ybreaks = NULL, size = 2.8, bw = FALSE, srs = NULL,
  plot = TRUE)

Arguments

trans

Data frame with the complete transport information of interest species. Must be generated using conc2frac. This is the only non-optional parameter.

trend

Non-linear regression model of the main transport profile generated using transTrend.

secondary

Secondary species transport data frame (see conc2frac).

tertiary

Tertiaty species transport data frame (see conc2frac).

sec.trend

Type of trend line to be used for secondary and tertiary species data. Default is 'spline' but 'linear', 'loess' and 'logarithmic' are also allowed.

lin.secon

Deprecated. Use sec.trend = 'linear' instead.

span

Amount of smoothing when sec.tred = 'loess'. Is a value between 0 and 1. Default is 0.75

legend

Logical. If FALSE, the default, the legend is not included.

xlab

Label to be used for x axis. Text and expression allowed.

ylab

Label to be used for y axis. Text and expression allowed.

xlim

Numeric vector of limits for X-axis.

ylim

Numeric vector of limits for X-axis.

xbreaks

Numeric vector of x-axis breaks.

ybreaks

Numeric vector of x-axis breaks.

size

Size used for points in the plot.

bw

Logical, if FALSE, the default, a color version of the plot is given. If a black and white version is required, it must be set to TRUE.

srs

Deprecated.

plot

Logical. If TRUE, the default, the plot is printed in the current graphical device.

Details

Most transmem graphical representations are made using the package ggplot2 so the function returns a ggplot2 object that can be assigned to a variable for further modification.

This function has a version that uses replicated experiments and may be useful to illustrate repeateability. For more information see transPlotWR.

Value

Plot of the transport profile considering all provided species.

Author(s)

Cristhian Paredes, craparedesca@unal.edu.co

Eduardo Rodriguez de San Miguel, erdsmg@unam.mx

References

Wickham H (2016). ggplot2: Elegant Graphics for Data Analysis. Springer-Verlag New York. ISBN 978-3-319-24277-4, https://ggplot2.tidyverse.org.

Examples

1
2
3
4
5
6
7
8
  data(seawaterLiNaK)
  trend <- transTrend(trans = seawaterLiNaK$Lithium.1, model = 'paredes')
  transPlot(trans = seawaterLiNaK$Lithium.1, trend = trend,
            secondary = seawaterLiNaK$Sodium.1,
            tertiary = seawaterLiNaK$Potassium.1)
  transPlot(trans = seawaterLiNaK$Lithium.1, trend = trend,
            secondary = seawaterLiNaK$Sodium.1,
            tertiary = seawaterLiNaK$Potassium.1, bw = TRUE)

transmem documentation built on July 1, 2020, 10:38 p.m.