mc.agg: Aggregation of classification results

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/mcfct.r

Description

Aggregate accest objects and list of accest objects to form mc.agg object. The main utilities of this function is to concatenate in a single list various results derived from several accest calls in order to facilitate post analysis additional treatments as well as exporting the results.

Usage

1
2
3
4
mc.agg(...)

## Default S3 method:
mc.agg(...)

Arguments

...

accest objects and or list of accest objects

Details

The length of the resulting list is equal to the total number of accest objects (i.e one resampling experiment) plus one field that summarises each accest. The later is a table with 8 columns which are automatically generated to and also avoid confusions if the same method is applied on the same discrimination problem but with different settings, different resampling partitioning or even different data sets. Note that columns 1 to 5 are automatically generated from the output of accest where as columns 6 is based on columns 2-4. Each column is described as follows:

Mod:

Unique identifier for each resampling based feature rankings.

Alg:

Name of the classification technique as specified in the call of accest.

Arg:

Arguments passed to the classifier during the call of accest.

Pars:

Summary of the resampling strategy adopted during the call of accest.

Dis:

Discrimination task involved. By default, this is equal to the actual levels of the class vector passed to accest separated by ~.

AlgId:

Unique algorithm identifier based on the columns Alg, Arg and Pars so that no confusion is possible with Alg column if several classification have been performed with the same discrimination technique but with different parameters and/or resampling strategy. This column can be modified by the user.

DisId:

Unique algorithm identifier based on the columns Dis in order to simplified the name of the discrimination task if there are many classes involved and/or class level have a long name. This column can be modified by the user.

Other:

Empty column that can be amended to store extra information.

Value

mc.agg objects:

clas

List of accest objects

cldef

Summary of each accest object - See details

Author(s)

David Enot [email protected]

See Also

accest,mc.summary, mc.comp.1, 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
23
24
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 = "boot",niter = 2, nreps=10)
dat1=dat.sel1(dat,cl,pwise=list(),mclass=list(),pars=pars)

res1=accest(dat1[[1]],clmeth="randomForest",ntree=100,seed=1)
res2=lapply(dat1,function(x) accest(x,clmeth="lda"))

mc=mc.agg(res1,res2)
###Print the content
mc

### Classification task num. 1:
mc$clas[[1]]

## As other functions are using the column 5 and 6 to sort and print the results,
## you can replace them by something more informative
## for e.g. Alg and Dis
mc$cldef[,6]<-mc$cldef[,2]
mc$cldef[,7]<-c("set~vir","set~vir","set~vir","ver~vir","ver~vir")
mc$cldef

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