plot.mc.roc: Plot multiple ROC curves

Description Usage Arguments Value Author(s) See Also Examples

View source: R/mcfct.r

Description

Plot multiple ROC curves contained in mc.roc objects (see details in mc.roc).

Usage

1
2
## S3 method for class 'mc.roc'
plot(x, leg = "Model", llty = NULL, lcol = NULL, xleg = 0.5, yleg = 0.4, ...)

Arguments

x

mc.roc object - See details in mc.roc

leg

User defined legend or select information from x$cldef

llty

List of symbols

lcol

List of colors

xleg

Upper left corner co-ordinate on the x-axis

yleg

Upper left corner co-ordinate on the y-axis

...

Further arguments to be passed to lines

Value

NULL

Author(s)

David Enot [email protected]

See Also

mc.roc

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
data(iris)
dat=as.matrix(iris[,1:4])
cl=as.factor(iris[,5])
lrnd=sample(1:150)[1:50]
cl[lrnd]=sample(cl[lrnd])
pars   <- valipars(sampling = "cv",niter = 2, nreps=10)
dat1=dat.sel1(dat,cl,pwise="virginica",mclass=NULL,pars=pars)

res1=lapply(dat1,function(x) accest(x,clmeth="lda"))
res2=lapply(dat1,function(x) accest(x,clmeth="randomForest",ntree=50))
mc=mc.agg(res1,res2)

roc.sv=mc.roc(mc,lmod=1:4)

### Default plot
plot(roc.sv)

###Improve plotting by using the names contained in the "DisId" and "Alg"
plot(roc.sv,leg=c("DisId","Alg"),llty=c(1,1,2,2),lcol=c("blue","red","blue","red"))

###Improve plotting by setting the legend
plot(roc.sv,leg=c("roc1","roc2","roc3","roc4"),llty=c(1,1,2,2),lcol=c("blue","red","blue","red"))

wilsontom/FIEmspro documentation built on Feb. 19, 2018, 9:03 a.m.