takes a dataframe that contains a column named lab such that mydf$lab gives the true labeling of the data. trainingRows is a vector identifying which rows should be training data. success is defined by a prediction probability being within the top targetSuccessRate*100 percent. Returns various success metrics.
1 2 | rkrnsRanker(mydfin, trainingRows, targetSuccessRate = 0.15,
whichmodel = "randomForest", verbose = FALSE)
|
1 2 3 4 5 | mylabs<-rep(c("a","b","c"),5)
voxeldata<-replicate(100, rnorm(length(mylabs)))
mydf<-data.frame( lab=mylabs, vox=voxeldata)
rfr<-rkrnsRanker( mydf, 1:round(nrow(mydf)/2), whichmodel='svm' )
print( rfr$successPercent )
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.