Draw for all posible cutoffs, TP, FP, TN, FN, sensitivity, specificity and more.
performance.plot.ade(pred, event, data=NULL, vnames=NULL, cutoffs=NULL,
cutnames=NULL, main=NULL, xlab="cutoff", ylab="%",
xlim=NULL, xticks=12,
col=NULL, tcol=NULL, bgcol=NULL, lcol=NULL, alpha=NULL,
nints=100, lty=NULL, lwd=2, stats=c(1, 2),
youden=TRUE, wall=0)
a numeric predictor vector
a string with the name of the variable in the data.frame
a formula yevent~pred
a numeric event vector
a string with the name of the variable in the data.frame
data.frame if used character string for (pred, event)
a vector of character strings with the labels for performance values in top legend
a vector of optional cutoffs, to draw vertical lines
a vector of character strings with the names for optional cutoffs
an overall title for the plot
a title for the x axis
a title for the y axis
the x limits (x1, x2) of the plot
the number of ticks on the x axis or a vector of exact ticks
a vector of 4 colors, for the 4 areas in the plot (TP, TN, FP, FN)
color of the text in whole plot
the background color for plot dekoration
color for the lines in plot, a vector of colors is possible
a parameter in [0, 1] for semi-transparency of points
number of points for the areas and curves, precision of calculation
a vector of line types
the line width for all lines, cutoff lines too
a number or vector of numbers from 1 to 4 indicate what statistics are to be drawn
1. Sensitivity
2. Specificity
3. PPV
4. NPV
logical asking whether to plot red line for youden-index maximum
a number between 0 and 6 for selection the dekoration style of the plot.
performance.plot.ade(rnorm(100), round(runif(100)))
Run the code above in your browser using DataLab