# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #块数量1:参数# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #库(MCRestimate)库(randomForest)库(golubEsets)数据(Golub_Train)类。科勒姆< -“所有。AML“# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #块数量2:功能# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # savepdf = function (x,文件、w = 10 h = 5) {pdf(=文件,宽度= w,身高= w); x; dev.off()}选项(宽度= 50)# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #块数量3:方法选择# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # Preprocessingfunctions < - c list.of.poss (“varSel.highest.var”)。参数< -列表(var.numbers = c(250、1000) # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #块数量4:方法选择# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #类。<——“射频功能。用“# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #块数量5:情节参数# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #阴谋。标签<——“样本”# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #块数量6:理由CROSS-VALIDSATION # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #的十字架。外< - 2交叉。< - 3交叉重复。内心的< - 2 # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #块数量7:射频。让# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # RF.estimate < - MCRestimate (Golub_Train、类。科勒姆,classification.fun = "射频。包”,thePreprocessingMethods = Preprocessingfunctions poss.parameters = list.of.poss。参数,cross.outer =十字架。外,cross.inner =十字架。内,cross.repeat =十字架。重复,plot.label = plot.label) # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #块数量8:射频。show ################################################### class(RF.estimate) ################################################### ### chunk number 9: RF eval=FALSE ################################################### ## plot(RF.estimate,rownames.from.object=TRUE, main="Random Forest") ################################################### ### chunk number 10: rf.save ################################################### savepdf(plot(RF.estimate,rownames.from.object=TRUE, main="Random Forest"),"RF.pdf") ################################################### ### chunk number 11: ################################################### RF.classifier <- ClassifierBuild (Golub_Train, class.colum, classification.fun="RF.wrap", thePreprocessingMethods=Preprocessingfunctions, poss.parameters=list.of.poss.parameter, cross.inner=cross.inner) ################################################### ### chunk number 12: ################################################### names(RF.classifier) ################################################### ### chunk number 13: test ################################################### data(Golub_Test) RF.classifier$classifier.for.exprSet(Golub_Test)