Plotting method for Daim Objects

Description

Plot a Daim object generated by the Daim function.

Usage

1
2
3
4
5
## S3 method for class 'Daim'
plot(x, method=NULL, all.roc=FALSE, color="red",
     alpha=0.25, type="s", xlab="False positive rate", 
     ylab="True positive rate", main=NULL, add=FALSE, 
     legend = FALSE, ...)

Arguments

x

an object of class Daim.

method

kind of the estimation of the ROC curve: '0.632+', '0.632', 'loob', 'cv', 'sample'

all.roc

logical. Should ROC curves from all samples be plotted ?

color

the color used to draw the ROC curve.

alpha

semi-transparent color: see rgb.

type

what type of plot should be drawn: see argument 'type' by the function plot.

xlab

a title for the x axis: see title.

ylab

a title for the y axis: see title.

main

a main title for the plot, see also title.

add

logical specifying if roc-area should be added to an already existing plot.

legend

add legend to plot.

...

graphical parameters can be given as arguments to 'plot'.

See Also

Daim, roc.area.Daim

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
  library(Daim)
  data(Daim.data1)
  perform <- performDaim(Daim.data1$prob.oob, Daim.data1$labels, Daim.data1$prob.app)
  summary(perform)

  par(mfrow=c(2,2))
  plot(perform, method="0.632+", legend=TRUE)
  plot(perform, method="sample")
  plot(perform, method="0.632+", main="Comparison between methods")
  plot(perform, method="0.632", col="blue", add=TRUE)
  plot(perform, method="loob", col="green", add=TRUE)
  legend("bottomright", c("0.632+","0.632","loob"),
         col=c("red","blue","green"), lty=1, inset=0.01)
  plot(perform, all.roc=TRUE)


  ####
  #### If your device don't support the semi-transparent colors use 
  #### the PDF Graphics Device.
  ####
   
  ## Not run: 
  pdf("plot-Daim.pdf")
  plot(perform, method="0.632+")
  plot(perform, method="sample")
  plot(perform, method="0.632+", main="Comparison between methods")
  plot(perform, method="0.632", col="blue", add=TRUE)
  plot(perform, method="loob", col="green", add=TRUE)
  legend("bottomright", c("0.632+","0.632","loob"),
         col=c("red","blue","green"), lty=1, inset=0.01)
  plot(perform, all.roc=TRUE)
  dev.off()
  
## End(Not run)