R: Add threshold lines to a plot (two-state setting)
lines.thres2
R Documentation
Add threshold lines to a plot (two-state setting)
Description
The function includes vertical lines for the threshold and confidence interval in a plot created with plot.thres2().
Usage
## S3 method for class 'thres2'
lines(x, ci = TRUE, which.boot = c("norm", "perc"),
col = 1, lty = c(1, 2), lwd = 1, ...)
Arguments
x
an object of class thres2.
ci
should the confidence interval be plotted? Default, TRUE.
which.boot
in case x contains confidence intervals computed by bootstrapping, which one should be printed? The user can choose between "norm" (based on normal distribution) or "perc" (based on percentiles). Default, "norm". This argument is ignored if the confidence intervals were computed by the delta method.
col
color for the threshold and its corresponding confidence interval. Default, 1.
lty
a 2-dimensional vector containing:
lty[1]: line type for the threshold
lty[2]: line type for the confidence interval
Default, c(1, 2).
lwd
line width for the threshold and its corresponding confidence interval. Default, 1.
...
further arguments to be passed to abline().
Value
With a plot.thres2 open, this function adds lines for the required threshold.
References
Skaltsa K, Jover L, Carrasco JL. (2010). Estimation of the diagnostic threshold accounting for decision costs and sampling uncertainty. Biometrical Journal 52(5):676-697.