plot.optimal.cutpoints: Default optimal.cutpoints plotting

Description Usage Arguments Author(s) See Also Examples

View source: R/plot.optimal.cutpoints.R

Description

On the basis of an optimal.cutpoints object, three plots are currently available: (1) a plot of the Receiver Operating Characteristic (ROC) curve; (2) a plot of the Predictive ROC (PROC) curve; and, in some methods, (3) a plot of the values of the optimal criterion used as a function of the cutoffs.

Usage

1
2
## S3 method for class 'optimal.cutpoints'
plot(x, legend = TRUE, which = c(1,2), ...)

Arguments

x

an object of class optimal.cutpoint as produced by optimal.cutpoints().

legend

a logical value for including the legend of optimal coordinates with specific characteristics. The default is TRUE.

which

a numeric vector with the required plots. By default, both the ROC and the PROC curves are plotted.

...

further arguments passed to method plot.default.

Author(s)

Monica Lopez-Raton and Maria Xose Rodriguez-Alvarez

See Also

optimal.cutpoints, control.cutpoints

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
library(OptimalCutpoints)
data(elas)
###########################################################
# Youden Index method ("Youden"): Covariate gender
###########################################################
optimal.cutpoint.Youden<-optimal.cutpoints(X = "elas", status = "status", tag.healthy = 0, 
methods = "Youden", data = elas, pop.prev = NULL, categorical.cov = "gender", 
control = control.cutpoints(), ci.fit = TRUE, conf.level = 0.95, trace = FALSE)

# Plot by default
plot(optimal.cutpoint.Youden)

#  Not including the optimal coordinates
plot(optimal.cutpoint.Youden, legend = FALSE)
# Change the colour
plot(optimal.cutpoint.Youden, col = "blue")    

Example output

Warning: Sensitivity CI: "Exact" method may not be valid for some values (see Help Manual).

Warning: Specificity CI: "Exact" method may not be valid for some values (see Help Manual).

Warning: Positive Predictive Value CI: "Exact" method may not be valid for some values (see Help Manual).

Warning: Negative Predictive Value CI: "Exact" method may not be valid for some values (see Help Manual).

Warning: Sensitivity CI: "Exact" method may not be valid for some values (see Help Manual).

Warning: Specificity CI: "Exact" method may not be valid for some values (see Help Manual).

Warning: Positive Predictive Value CI: "Exact" method may not be valid for some values (see Help Manual).

Warning: Negative Predictive Value CI: "Exact" method may not be valid for some values (see Help Manual).

Press return for next page....
Press return for next page....
Press return for next page....
Press return for next page....
Press return for next page....
Press return for next page....
Press return for next page....
Press return for next page....
Press return for next page....

OptimalCutpoints documentation built on Oct. 7, 2021, 5:09 p.m.