rfgini.Rd
Random Forest cumulative MeanDecreaseGini feature selection. Implements a feature selection approach based on cumulative MeanDecreaseGini using Random Forests trained on multiple subsamples.
rfgini(num_runs = 100, num_trees = 30, file_path = file_path)
num_runs | Number of subsamples to use for voting scheme (default: 100) |
---|---|
num_trees | Number of trees for random forest (selected using select_rf_numtrees) |
file_path | Where the num_runs subsample files are found (e.g. if sample 10 is at 'subsamples/sample10.csv' then file_path should be 'subsamples/sample'). There must be enough samples to fulfill num_runs runs. |
The function will output a data.frame with cumulative mean decrease in Gini for each feature in the first columns (each row is a feature) and the rest of the column containing mean decrease in Gini for each of the num_runs runs.
rfgini( num_runs=5, num_trees=30, file_path=paste(system.file('samples/subsamples',package = "feamiR"),'/sample',sep=''))#> X1 X2 X3 X4 X5 #> classification 0.00000000 NA NA NA NA #> position1_A 9.67317143 1.582002428 3.40411733 0.71150622 1.497320039 #> position1_C 7.28577887 0.806634501 2.30208080 1.65262495 2.215631525 #> position1_G 25.68960940 6.952940697 3.11981742 8.10516420 3.775531009 #> position1_U 52.40992370 10.797971360 9.64952006 8.08542177 12.254067636 #> position2_A 25.77796595 4.311312761 5.57533098 4.35466657 4.262815089 #> position2_C 11.29296726 2.795879513 1.73231357 2.79766073 2.570374009 #> position2_G 12.55309621 1.687594807 2.56337635 3.17529054 2.158934855 #> position2_U 14.98723079 4.329102420 2.24005450 3.15271469 2.749204359 #> position3_A 19.47158221 2.053852464 3.46417895 3.19111293 6.574970717 #> position3_C 20.10176572 4.621436840 4.21850568 2.43630491 5.115695750 #> position3_G 13.90768024 2.110341624 2.92139030 3.50405171 3.167278041 #> position3_U 16.69637560 5.210709713 3.51212343 1.81350826 1.723543576 #> position4_A 14.96964079 3.895227877 2.33097407 1.51620209 4.602654502 #> position4_C 18.98980414 6.058280318 2.92439479 2.10526352 3.437106672 #> position4_G 13.95669142 3.878817766 2.43320992 4.25316228 1.574969184 #> position4_U 14.51373290 3.112122064 2.75833590 5.37893114 1.121645499 #> position5_A 32.26624036 5.810082846 6.63293540 5.19981418 6.296189495 #> position5_C 19.55027147 5.252215564 2.53441935 3.13437066 6.024902262 #> position5_G 36.84530849 7.886000422 4.61947421 11.71692324 8.471978806 #> position5_U 37.89492886 8.369012960 10.89894639 6.43674654 6.512389912 #> position6_A 39.74629657 7.390135419 6.91251881 6.51688080 9.390857702 #> position6_C 35.41287331 6.353626839 8.86682999 8.13833744 5.279481963 #> position6_G 11.11102201 1.485646920 2.82570359 1.39576435 1.884687888 #> position6_U 11.43476175 2.332942742 2.82213100 1.64312957 2.162773869 #> position7_A 32.50163984 5.558555539 7.71219651 7.04800925 3.772123521 #> position7_C 19.66608617 3.544431803 3.71692897 2.91077319 4.702589506 #> position7_G 10.11272930 1.652520865 2.12662705 1.88116547 3.288072841 #> position7_U 16.60948991 3.808305724 3.08548318 3.03146677 3.780644556 #> position8_A 17.23898895 2.538554523 4.62414609 1.99190502 4.614214237 #> position8_C 20.21669789 3.114482097 6.66201668 4.99702070 2.068430418 #> position8_G 19.47540962 4.206980697 3.15933303 4.58944665 5.806056935 #> position8_U 13.53308642 1.566577715 3.85036596 2.48179561 3.221250100 #> pair1_AA 2.93746733 0.962386236 0.61960060 0.47121281 0.320859344 #> pair1_AC 2.88555404 0.339313634 0.62255481 0.31640857 1.138691985 #> pair1_AG 0.93379249 0.107655502 0.22661327 0.00000000 0.375791906 #> pair1_AU 8.16365476 1.473505269 1.01339890 2.14816946 2.179929700 #> pair1_CA 1.34078318 0.204842021 0.21182894 0.69421587 0.152676769 #> pair1_CC 1.01071678 0.412926198 0.19638387 0.00000000 0.000000000 #> pair1_CG 1.86868864 0.394203091 0.37832136 0.28539271 0.220996690 #> pair1_CU 2.11066961 0.966558823 0.00000000 0.10722407 0.479886530 #> pair1_GA 0.05955242 0.007563025 0.00000000 0.00000000 0.000000000 #> pair1_GC 0.21527696 0.000000000 0.00000000 0.03356643 0.181710526 #> pair1_GG 0.85373782 0.000000000 0.19501020 0.04480287 0.397747466 #> pair1_GU 4.62579255 0.184391778 1.04866950 1.65683645 1.351942533 #> pair1_UA 16.79010196 2.253939928 4.25704755 4.12295179 3.429695459 #> pair1_UC 7.77189781 0.707441500 2.81313689 1.63788218 1.387264226 #> pair1_UG 27.01220846 7.211947188 8.67291395 4.14160057 3.068044003 #> pair1_UU 18.15524224 6.088858594 1.48826476 1.83459649 4.468260133 #> pair2_AA 11.05872306 1.125926641 4.03316462 0.88836169 2.969370322 #> pair2_AC 0.97230810 0.051567379 0.38539133 0.11241395 0.050447761 #> pair2_AG 1.99583659 0.559589580 0.47247561 0.59401799 0.035555556 #> pair2_AU 27.26274697 5.071018338 6.27724051 4.71782438 5.361788239 #> pair2_CA 4.18281858 1.119143110 0.56418862 0.44025108 1.358772200 #> pair2_CC 0.20920413 0.051282051 0.06000000 0.02077922 0.077142857 #> pair2_CG 5.18625001 0.890563281 1.19625267 0.95520766 1.244061906 #> pair2_CU 2.65250841 0.334490439 0.79802075 0.44639890 0.385918003 #> pair2_GA 15.12910586 3.276157864 2.23438859 3.11619938 2.755368102 #> pair2_GC 2.37230397 0.488660353 0.36296399 0.50220522 0.539222745 #> pair2_GG 22.14599378 4.924537557 1.84738452 6.01570360 1.911875080 #> pair2_GU 4.71428542 1.023473118 0.49146767 2.09645154 0.810028086 #> pair2_UA 11.93862757 0.555361394 3.84033588 1.86484746 1.941946340 #> pair2_UC 0.64610688 0.369938469 0.00000000 0.00000000 0.000000000 #> pair2_UG 5.89210398 0.693861414 0.29340391 1.11188619 2.088022483 #> pair2_UU 4.17145876 1.164938009 0.68683734 0.42316990 0.282827840 #> pair3_AA 7.09189235 1.530349454 0.64456310 1.41127351 2.783524838 #> pair3_AC 44.13575071 10.221678243 5.83669866 10.59508567 11.162400112 #> pair3_AG 7.91348768 1.731873320 1.18625902 1.80818038 1.410723870 #> pair3_AU 6.89477238 1.021564577 0.78602998 2.34063457 1.273406572 #> pair3_CA 1.55958922 0.000000000 0.29119119 0.57384561 0.688236639 #> pair3_CC 0.00000000 0.000000000 0.00000000 0.00000000 0.000000000 #> pair3_CG 0.16142256 0.066666667 0.04740741 0.00000000 0.000000000 #> pair3_CU 3.22018623 0.895783161 0.64477120 0.15992008 0.737988008 #> pair3_GA 20.33569388 5.146109849 3.16200552 5.38553247 2.848893130 #> pair3_GC 2.17234676 0.014613527 0.44537981 0.36240810 0.812794999 #> pair3_GG 2.21986095 0.532028955 0.29467529 0.21029086 0.838011134 #> pair3_GU 3.49141918 0.987020179 1.27874227 0.38430981 0.257933297 #> pair3_UA 9.68698274 2.973710219 3.32524242 0.08145017 2.045860869 #> pair3_UC 7.04549258 0.993311833 2.17391458 0.93711960 1.193863028 #> pair3_UG 6.52585904 1.542137646 1.77622801 0.94717997 1.110755018 #> pair3_UU 22.30185931 5.366886452 1.54164247 5.06291955 6.637614004 #> pair4_AA 31.99868924 6.511221315 6.88788538 6.90950934 5.100745358 #> pair4_AC 0.66279458 0.000000000 0.17100445 0.25282717 0.000000000 #> pair4_AG 5.12032896 1.025947028 1.41407838 0.40339906 0.847678291 #> pair4_AU 17.52171591 2.189753053 6.14515314 1.30142718 3.593567946 #> pair4_CA 8.26219471 2.098169608 1.75002553 2.19533860 1.178113391 #> pair4_CC 0.41069278 0.159114720 0.10023229 0.02117647 0.130169304 #> pair4_CG 43.61040795 9.748493596 11.92200496 9.99992890 6.199986810 #> pair4_CU 3.59507565 0.933132701 0.71344474 0.17611788 1.130688093 #> pair4_GA 5.90330849 0.215281385 1.48027910 0.12963037 1.942878993 #> pair4_GC 0.58562123 0.000000000 0.13018136 0.45543987 0.000000000 #> pair4_GG 4.30384051 0.747056433 0.69244520 1.36315258 0.511635012 #> pair4_GU 5.60624920 1.737428454 1.19479941 0.78493019 0.917679146 #> pair4_UA 10.79963238 2.684139718 1.21694256 3.35073662 1.757853327 #> pair4_UC 0.81462349 0.316828696 0.01111111 0.03959596 0.261770263 #> pair4_UG 24.06533780 6.820222439 1.27396498 3.08350101 7.088955445 #> pair4_UU 2.13912540 0.532266243 0.41324722 0.34583849 0.451829842 #> pair5_AA 3.96822740 0.508992607 1.20426563 0.52265334 1.294308462 #> pair5_AC 9.59029670 2.106219656 0.40861933 2.30354413 2.456115204 #> pair5_AG 26.47360648 6.559359713 4.83176964 6.17137358 5.950368768 #> pair5_AU 9.16916257 2.637052232 1.50318370 1.33382890 1.260342254 #> pair5_CA 2.57984264 0.135823430 1.19969829 0.13876533 0.801000601 #> pair5_CC 0.43740903 0.090444017 0.02708535 0.08956554 0.230314129 #> pair5_CG 0.79495240 0.004658385 0.62116764 0.05680493 0.055453149 #> pair5_CU 0.43522594 0.013333333 0.01166667 0.00000000 0.146693883 #> pair5_GA 2.62300641 1.178007131 0.03366300 0.80072960 0.545222060 #> pair5_GC 58.63225365 13.439695537 7.47595711 15.06125888 8.687679338 #> pair5_GG 3.23051842 0.130195462 1.01596602 0.01111111 1.648209479 #> pair5_GU 19.00626536 2.770803908 2.38028338 3.64793610 3.620809684 #> pair5_UA 5.42502214 0.876920339 1.93277267 1.20175498 0.827556490 #> pair5_UC 3.78249540 1.109079550 0.69851115 1.01784848 0.433289182 #> pair5_UG 5.22703395 1.429395414 1.45574789 0.61855340 0.544225614 #> pair5_UU 9.25489306 1.012119119 2.54936877 1.47207698 2.821420292 #> pair6_AA 9.51991808 2.182833731 1.93751940 0.63087054 1.775533743 #> pair6_AC 1.85577808 0.000000000 1.06366291 0.09684006 0.223148295 #> pair6_AG 10.00662018 2.901463358 1.46973012 1.52022486 2.632527806 #> pair6_AU 6.24527424 0.417985345 2.62702876 1.93549076 0.730037590 #> pair6_CA 14.44152416 3.410636702 3.03715539 4.37734220 1.196275221 #> pair6_CC 0.72015961 0.000000000 0.36807694 0.10513296 0.106568531 #> pair6_CG 1.24197047 0.419785595 0.49342460 0.13509598 0.193664303 #> pair6_CU 31.23042877 5.543718687 8.89080333 8.12798503 4.142556726 #> pair6_GA 9.27891674 0.158863451 1.31564774 2.13160772 4.001318889 #> pair6_GC 5.49343099 1.422734502 1.14459386 1.34109742 1.258954576 #> pair6_GG 2.41506206 0.379121075 0.46870591 0.33400889 0.504998734 #> pair6_GU 2.59512818 0.751556344 0.46574830 0.29992619 0.506998412 #> pair6_UA 24.28892843 4.917541446 3.37747568 5.37228139 3.077243319 #> pair6_UC 2.29623645 0.000000000 0.10736467 1.20857405 0.711390368 #> pair6_UG 6.90687186 1.000396324 0.93596533 3.20862140 0.891457080 #> pair6_UU 4.31727301 0.549489804 1.38184935 1.16528950 0.267202381 #> pair7_AA 5.99629336 1.444643992 1.36451973 0.98549256 1.294706715 #> pair7_AC 48.86607646 4.915217848 10.60118998 11.00286621 10.080547863 #> pair7_AG 10.76480031 1.298542301 2.01406392 3.40848318 2.510334347 #> pair7_AU 15.35291616 4.935445927 2.72942640 1.83401953 3.775340669 #> pair7_CA 1.89217730 0.367618972 0.57149296 0.03458976 0.697257005 #> pair7_CC 0.25363323 0.000000000 0.03340235 0.03841270 0.181818182 #> pair7_CG 0.62975426 0.075020839 0.00000000 0.03333695 0.169986529 #> pair7_CU 6.36746125 1.099421963 1.13288807 2.06374204 0.784907960 #> pair7_GA 6.71913513 0.756652266 1.79172948 2.08457677 0.992627492 #> pair7_GC 0.42551346 0.050000000 0.04573787 0.15912014 0.145034526 #> pair7_GG 1.83299054 0.395401960 0.55754743 0.28167063 0.105497812 #> pair7_GU 7.15764862 1.113661456 1.12632991 2.20358920 1.941723658 #> pair7_UA 3.06029935 1.274985713 1.08979389 0.05482993 0.004415253 #> pair7_UC 1.90920308 0.305612295 0.90023694 0.27043624 0.267702682 #> pair7_UG 12.08171031 2.512474831 3.02080356 2.87157025 2.065615407 #> pair7_UU 8.59544526 1.104105742 1.74415838 3.47565916 0.861748951 #> X6 #> classification NA #> position1_A 2.478225423 #> position1_C 0.308807092 #> position1_G 3.736156077 #> position1_U 11.622942869 #> position2_A 7.273840554 #> position2_C 1.396739436 #> position2_G 2.967899655 #> position2_U 2.516154821 #> position3_A 4.187467149 #> position3_C 3.709822539 #> position3_G 2.204618566 #> position3_U 4.436490623 #> position4_A 2.624582255 #> position4_C 4.464758836 #> position4_G 1.816532269 #> position4_U 2.142698299 #> position5_A 8.327218431 #> position5_C 2.604363635 #> position5_G 4.150931811 #> position5_U 5.677833057 #> position6_A 9.535903834 #> position6_C 6.774597080 #> position6_G 3.519219266 #> position6_U 2.473784566 #> position7_A 8.410755010 #> position7_C 4.791362706 #> position7_G 1.164343076 #> position7_U 2.903589679 #> position8_A 3.470169090 #> position8_C 3.374747989 #> position8_G 1.713592305 #> position8_U 2.413097044 #> pair1_AA 0.563408328 #> pair1_AC 0.468585043 #> pair1_AG 0.223731816 #> pair1_AU 1.348651436 #> pair1_CA 0.077219575 #> pair1_CC 0.401406719 #> pair1_CG 0.589774795 #> pair1_CU 0.557000191 #> pair1_GA 0.051989390 #> pair1_GC 0.000000000 #> pair1_GG 0.216177281 #> pair1_GU 0.383952290 #> pair1_UA 2.726467244 #> pair1_UC 1.226173009 #> pair1_UG 3.917702753 #> pair1_UU 4.275262260 #> pair2_AA 2.041899780 #> pair2_AC 0.372487685 #> pair2_AG 0.334197860 #> pair2_AU 5.834875506 #> pair2_CA 0.700463576 #> pair2_CC 0.000000000 #> pair2_CG 0.900164500 #> pair2_CU 0.687680313 #> pair2_GA 3.746991923 #> pair2_GC 0.479251661 #> pair2_GG 7.446493023 #> pair2_GU 0.292865008 #> pair2_UA 3.736136492 #> pair2_UC 0.276168411 #> pair2_UG 1.704929993 #> pair2_UU 1.613685666 #> pair3_AA 0.722181440 #> pair3_AC 6.319888026 #> pair3_AG 1.776451092 #> pair3_AU 1.473136682 #> pair3_CA 0.006315789 #> pair3_CC 0.000000000 #> pair3_CG 0.047348485 #> pair3_CU 0.781723783 #> pair3_GA 3.793152916 #> pair3_GC 0.537150319 #> pair3_GG 0.344854701 #> pair3_GU 0.583413622 #> pair3_UA 1.260719066 #> pair3_UC 1.747283539 #> pair3_UG 1.149558407 #> pair3_UU 3.692796837 #> pair4_AA 6.589327852 #> pair4_AC 0.238962963 #> pair4_AG 1.429226196 #> pair4_AU 4.291814592 #> pair4_CA 1.040547580 #> pair4_CC 0.000000000 #> pair4_CG 5.739993681 #> pair4_CU 0.641692232 #> pair4_GA 2.135238642 #> pair4_GC 0.000000000 #> pair4_GG 0.989551279 #> pair4_GU 0.971411998 #> pair4_UA 1.789960153 #> pair4_UC 0.185317460 #> pair4_UG 5.798693926 #> pair4_UU 0.395943606 #> pair5_AA 0.438007362 #> pair5_AC 2.315798370 #> pair5_AG 2.960734782 #> pair5_AU 2.434755488 #> pair5_CA 0.304554992 #> pair5_CC 0.000000000 #> pair5_CG 0.056868286 #> pair5_CU 0.263532055 #> pair5_GA 0.065384615 #> pair5_GC 13.967662792 #> pair5_GG 0.425036342 #> pair5_GU 6.586432284 #> pair5_UA 0.586017663 #> pair5_UC 0.523767048 #> pair5_UG 1.179111634 #> pair5_UU 1.399907910 #> pair6_AA 2.993160664 #> pair6_AC 0.472126820 #> pair6_AG 1.482674047 #> pair6_AU 0.534731786 #> pair6_CA 2.420114643 #> pair6_CC 0.140381177 #> pair6_CG 0.000000000 #> pair6_CU 4.525364998 #> pair6_GA 1.671478935 #> pair6_GC 0.326050632 #> pair6_GG 0.728227451 #> pair6_GU 0.570898930 #> pair6_UA 7.544386592 #> pair6_UC 0.268907362 #> pair6_UG 0.870431726 #> pair6_UU 0.953441977 #> pair7_AA 0.906930364 #> pair7_AC 12.266254557 #> pair7_AG 1.533376558 #> pair7_AU 2.078683628 #> pair7_CA 0.221218607 #> pair7_CC 0.000000000 #> pair7_CG 0.351409943 #> pair7_CU 1.286501221 #> pair7_GA 1.093549117 #> pair7_GC 0.025620915 #> pair7_GG 0.492872697 #> pair7_GU 0.772344400 #> pair7_UA 0.636274566 #> pair7_UC 0.165214920 #> pair7_UG 1.611246262 #> pair7_UU 1.409773031