Description Usage Arguments Value References See Also Examples
A hyperSMURF model is tested on a given data set. Predictions of each RF of the hyperensemble are performed sequentially and the scores of each ensemble are finally averaged.
1 | hyperSMURF.test(data, HSmodel)
|
data |
a data frame or matrix with the test data. Rows: examples; columns: features |
HSmodel |
a list including the trained random forest models. The models have been trained with |
a named vector with the computed probabilities for each example (hyperSMURF score)
M. Schubach, M. Re, P.N. Robinson and G. Valentini Imbalance-Aware Machine Learning for Predicting Rare and Common Disease-Associated Non-Coding Variants, Scientific Reports, Nature Publishing, 7:2959, 2017.
1 2 3 4 5 6 7 8 9 10 | train <- imbalanced.data.generator(n.pos=20, n.neg=1000,
n.features=10, n.inf.features=2, sd=0.1, seed=1);
HSmodel <- hyperSMURF.train(train$data, train$label,
n.part = 5, fp = 1, ratio = 2, k = 5);
test <- imbalanced.data.generator(n.pos=20, n.neg=1000,
n.features=10, n.inf.features=2, sd=0.1, seed=2);
res <- hyperSMURF.test(test$data, HSmodel);
y <- ifelse(test$labels==1,1,0);
pred <- ifelse(res>0.5,1,0);
table(pred,y);
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.