findFinalClassifier-methods: findFinalClassifier Method to train and build the final...

Description Value Methods See Also Examples

Description

This method generates and stores the final classifier corresponding to an assessment. This classifier can then be used to classify new samples by calling classifyNewSamples. The final classifier is build according to the classifier selected for a given assessment, applied on the whole data considering only the genes selected by the feature selction method selected.

Value

The methods returns an object of class assessment which finalClassifier has been build.

Methods

object = "assessment"

This method is only applicable on objects of class assessment.

See Also

finalClassifier, assessment

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
#dataPath <- file.path("C:", "Documents and Settings", "c.maumet", "My Documents", "Programmation", "Sources", "SVN", "R package", "data")
#aDataset <- new("dataset", dataId="vantVeer_70", dataPath=dataPath)
#aDataset <- loadData(aDataset)
data('vV70genesDataset')

# With the RFE-SVM as feature selection method
expeOfInterest <- new("assessment", dataset=vV70genes,
                                   noFolds1stLayer=10,
                                   noFolds2ndLayer=9,
                                   classifierName="svm",
                                   typeFoldCreation="original",
                                   svmKernel="linear",
                                   noOfRepeat=2,
                                   featureSelectionOptions=new("geneSubsets", optionValues=c(1,2,4,8,16,32,64,70)))

# Build the final classifier
expeOfInterest <- findFinalClassifier(expeOfInterest)

# With the NSC as feature selection method
expeOfInterest <- new("assessment", dataset=vV70genes,
                                   noFolds1stLayer=10,
                                   noFolds2ndLayer=9,
                                   featureSelectionMethod="nsc",
                                   classifierName="nsc",
                                   typeFoldCreation="original",
                                   svmKernel="linear",
                                   noOfRepeat=2,
                                   featureSelectionOptions=new("thresholds"))

# Build the final classifier
expeOfInterest <- findFinalClassifier(expeOfInterest)

Rmagpie documentation built on Nov. 8, 2020, 11:09 p.m.