rra.plot {iRRA}R Documentation

Plotting the RoI

Description

This function will plot a "rra_result" object obtained by the rra function. It will draw the RoI space together with the ROC curve. It will also highlight the RoI under the curve.

Usage

  rra.plot(rra_result, ADD = FALSE,
           cROI = "grey", cUnder = "light blue",
           type = "l", diagonal = TRUE,
           xlim = c(0,1), ylim = c(0,1), asp = 0,
           xlab = "FP/AN", ylab = "TP/AP",
           main = "ROC curve and RoI", ...)

Arguments

rra_result

A "rra_result" object obtained by rra

ADD

If the user wants to keep the elements he already drawn

cROI

The color of the RoI space. By default, it's grey. It is used as a normal col parameter of any plot function

cUnder

The color of the RoI space under the ROC curve. By default, it's light blue. It is used as a normal col parameter of any plot.default function

diagonal

If the user wants to plot the y = x diagonal

type, xlim, ylim, asp, xlab, ylab, main

These are normal plot.default parameters but with a default value

...

Others plot.default parameters that can be used to personalize the ROC curve, such as lwd

Note

Note that the RoI is plotted as a polygon. It could hide other plotted structures if ADD = TRUE. In this case, consider using something like adjustcolor("color_name", alpha.f=0.5) to give some transparency to the polygons.

If main = "" or NULL, xlab = "" or NULL or xlab = "" or NULL, the margins will adapt so that as little space as possible is wasted

See Also

rra

Examples

## Not run: 
# They can be run if one has already computed a "rra_result" object.

rra.plot(rra_result)
#It will draw the curve and the RoI with the dafault values.

rra.plot(rra_result, cROI = "green", cUnder = "red")
#The RoI will be green and the space under the curve red

rra.plot(rra_result, cROI = "green", col = "red", lwd = 2)
#The RoI will be green. Also, the ROC curve will be wider and red

## End(Not run)

[Package iRRA version 0.1.0 Index]