Plot Results of Analytical Duplicate Analyses as Ratios, Alternate Input
Function to prepare data stored in alternate forms from that expected by function ad.plot3
for its use, for further details see x
in Arguments below. The data will be plotted as ratios, i.e. dup1/dup2
, with logarithmic scaling relative to their means.
ad.plot4(x, xname = deparse(substitute(x)), if.order = FALSE, ad.tol = NULL, ifalt = FALSE, ldl = NULL, maxrat = NULL, if.text = FALSE, if.cpp = FALSE, ...)
x |
a column vector from a matrix or data frame, |
xname |
a title can be displayed with the plot and results, e.g., |
if.order |
by default the analytical duplicate results are plotted in the order in which they occur in the data file, this usually corresponds to date of analysis. Alternately, setting |
ad.tol |
optionally a tolerance level may be provided for the maximum acceptable percent ratio between duplicates, in which case a red dotted line is added to the plot. |
ifalt |
set |
ldl |
if the lower detection limit (ldl) of the analytical procedure is provided and falls within the range of the duplicate means it will be plotted as a vertical black dotted line. If another colour is required, e.g., red, set |
maxrat |
optionally the maximum ratio for the plot axis, the minimum is computed as |
if.text |
if set |
if.cpp |
if set |
... |
any additional arguments to be passed to the |
Data may be as a single concatenated vector from a matrix or data frame as x1[1], ..., x1[n]
followed by x[n+1], ..., x[2n]
, or alternated as x[1]
and x[2]
being a pair through to x[2*i+1]
and x[2*i+2]
for the i in 1:n
duplicate pairs, see ifalt
.
If the data are as n duplicate pairs, x1
and x2
, use function ad.plot3
.
Any less than detection limit values represented by negative values, or zeros or other numeric codes representing blanks in the data, must be removed prior to executing this function, see ltdl.fix.df
.
Robert G. Garrett
## Make test data available data(ad.test) attach(ad.test) ## Plot analytical duplicate analyses as ratios in acquistion sequence ad.plot4(Cu, ifalt = TRUE) ## Plot analytical duplicate analysis ratios against their means with ## more informative annotation ad.plot4(Cu, "Cu (mg/kg)", ifalt = TRUE, if.order = FALSE) ## Plot analytical duplicate analysis ratios against their means with a ## CPP of the ratios and more informative annotation ad.plot4(Cu, "Cu (mg/kg)", ifalt = TRUE, if.order = FALSE, if.cpp = TRUE) ## Detach test data detach(ad.test)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.