SWAP.GetKTSP.Result {switchBox} | R Documentation |
Given a kTSP classifier and data matrix and class labels, calculates the predictions and
vote sums and then applies SWAP.GetKTSP.PredictionStats
.
SWAP.GetKTSP.Result(classifier, inputMat, Groups, classes=NULL, predictions=FALSE, decision_values=FALSE)
classifier |
a k-TSP classifier computed using
|
inputMat |
is a matrix of data with rows being the features (such as gene names, if the matrix if gene expression data) and columns being the samples. |
Groups |
is a factor or a vector providing the phenotype class
each sample belongs to. It should correspond to the order of samples
given by the columns of |
classes |
is a vetor of length 2 providing the two phenotype or
class labels of |
predictions |
is a logical indicating whether to return the predictions or not. |
decision_values |
is a logical indicating whether to return the decision values or not. |
A list with items:
stats |
A vector providing accuracy, sensitivity, specificity, balanced accuracy, and AUC. |
roc |
An ROC curve object produced by the |
Bahman Afsari bahman.afsari@gmail.com, Luigi Marchionni marchion@jhu.edu, Wikum Dinalankara wdinala1@jhmi.edu
See switchBox for the references.
### Load gene expression data data(trainingData) data(testingData) require(pROC) ### train 1-TSP classifier = SWAP.Train.1TSP(matTraining, trainingGroup) ### get performance results SWAP.GetKTSP.Result(classifier, matTesting, testingGroup)$stats