plot.lmcal: Calibration plots

Description Usage Arguments Author(s) Examples

Description

Plot various plots commonly used to illustrate callibration.

Usage

1
2
3
4
5
6
7
8
## S3 method for class 'lmcal'
plot(x, type = c("curve", "residuals", "chronologic", "qqplot", "cook",
  "optimization"), trend = TRUE, confidence = TRUE, prediction = TRUE, 
  lines = c(1, 2, 3, 4), colors = c(1, 1, 1, 1, 1), xlab = NULL, ylab = NULL, ...)
## S3 method for class 'nlscal'
plot(x, type = c("curve", "residuals", "chronologic", "qqplot"),
  trend = TRUE, lines = c(1, 2, 3, 4), colors = c(1, 1, 1, 1, 1), xlab = NULL, 
  ylab = NULL, ...)

Arguments

x

An object of 'lmcal' or 'nlscal' class, respectively

type

Type of plots: curve - calibration plots, residuals - residuals vs. x values (common residual plot), chronologic - residuals in chronologic order (for autocorrelation detection), qqplot - quantile-quantile plots of residuals, cook - cook's distances, optimization - plots of weighting and Box-Cox optimization

trend

Logical: should be the trend of residuals marked (obtained by 'loess')

confidence

Logical: if the confidence interval should be plotted

prediction

Logical: if the prediction interval should be plotted

lines

Line types of the plot

colors

Colors of the plot

xlab

Label of x

ylab

Label of y

...

Additional arguments, currently ignored

Author(s)

Lukasz Komsta

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
x = rep(1:10,5)
y = jitter(sqrt(x))
fit = lmcal(x,y)
par(mfrow=c(2,2))
plot(fit,type="curve")
plot(fit,type="residuals")
plot(fit,type="optimization")
par(mfrow=c(1,1))
# Low level plotting, useful for customizing plot!
plot(x,y)
lines(fit$graph$grid,fit$graph$fitted$p1,lty=2)
lines(fit$graph$grid,fit$graph$fitted$p2,lty=2)

Example output

Loading required package: MASS
Loading required package: outliers
------------------------------------------
If you use this package, please cite the recent paper containing description of this software:
Komsta, L. Chemometric and statistical evaluation of calibration curves in pharmaceutical analysis 
           - a short review on trends and recommendations. J. AOAC Int. 2012, 95, 3, 669-672.
------------------------------------------
There were 15 warnings (use warnings() to see them)

quantchem documentation built on May 30, 2017, 5:28 a.m.