|
test(classifier,
data,
**args)
test a classifier on a given dataset |
source code
|
|
|
|
|
|
|
cv(classifier,
data,
numFolds=5,
**args)
perform k-fold cross validation |
source code
|
|
|
stratifiedCV(classifier,
data,
numFolds=5,
**args)
perform k-fold stratified cross-validation; in each fold the number of
patterns from each class is proportional to the relative fraction of the
class in the dataset |
source code
|
|
|
nCV(classifier,
data,
**args)
runs CV n times, returning a 'ResultsList' object. |
source code
|
|
|
makeFolds(data,
numFolds,
datasetName,
directory='.')
split a dataset into several folds and save the training and testing
data of each fold as a separate dataset |
source code
|
|
|
cvFromFile(classifier,
trainingBase,
testingBase,
datasetClass,
**args)
perform CV when the training and test data are in files whose names
are of the form:
trainingBase + number + string
and
testingBase + number + string
For example:
training0.data, training1.data, training2.data
and
testing0.data, testing1.data, testing2.data
for 3 fold CV. |
source code
|
|
|
scatter(r1,
r2,
statistic='roc',
x1Label='',
x2Label='',
fileName=None,
**args)
a scatter plot for comparing the performance of two classifiers |
source code
|
|
|
plotROC2(decisionFunc,
givenY,
fileName=None,
**args) |
source code
|
|
|
plotROC(res,
fileName=None,
**args)
plot the ROC curve from a given Results (or Results-like) object |
source code
|
|
|
plotROCs(resList,
descriptions=None,
fileName=None,
**args)
plot multiple ROC curves. |
source code
|
|
|
significance(r1,
r2,
statistic='roc')
report the statistical significance of the difference in error rates
of a series of classification results of two classifiers
using the Wilcoxon signed rank test. |
source code
|
|
|
trainTest(classifierTemplate,
data,
trainingPatterns,
testingPatterns,
**args)
Train a classifier on the list of training patterns, and test it
on the test patterns |
source code
|
|
|
confmat(L1,
L2)
computes the confusion matrix between two labelings |
source code
|
|
|
superConfmat(Y1,
Y2,
numClasses=0)
computes the confusion matrix between two labelings, where
the matrix is assumed to be square, according to the labels of L1
L1 and L2 are assumed to have integer components in the range
0,.., numClasses |
source code
|
|
|
roc(Y,
givenY,
decisionFunc,
n=None,
targetClass=1,
normalize=True)
Compute the ROC curve and area under the curve for a two class problem |
source code
|
|
|
|
|
|
|
loadResults(fileName,
isNewFormat=True)
isNewFormat -- whether the Results were saved under version 0.6.1 or newer |
source code
|
|
|
loadResults2(fileName)
load a list of list of Results objects or a dictionary of a list of Results objects |
source code
|
|