Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

prediction-class

Class prediction


Description

Object to encapsulate numerical predictions together with the corresponding true class labels, optionally collecting predictions and labels for several cross-validation or bootstrapping runs.

Slots

predictions

A list, in which each element is a vector of predictions (the list has length > 1 for x-validation data.

labels

Analogously, a list in which each element is a vector of true class labels.

cutoffs

A list in which each element is a vector of all necessary cutoffs. Each cutoff vector consists of the predicted scores (duplicates removed), in descending order.

fp

A list in which each element is a vector of the number (not the rate!) of false positives induced by the cutoffs given in the corresponding 'cutoffs' list entry.

tp

As fp, but for true positives.

tn

As fp, but for true negatives.

fn

As fp, but for false negatives.

n.pos

A list in which each element contains the number of positive samples in the given x-validation run.

n.neg

As n.pos, but for negative samples.

n.pos.pred

A list in which each element is a vector of the number of samples predicted as positive at the cutoffs given in the corresponding 'cutoffs' entry.

n.neg.pred

As n.pos.pred, but for negatively predicted samples.

Objects from the Class

Objects can be created by using the prediction function.

Note

Every prediction object contains information about the 2x2 contingency table consisting of tp,tn,fp, and fn, along with the marginal sums n.pos,n.neg,n.pos.pred,n.neg.pred, because these form the basis for many derived performance measures.

Author(s)

Tobias Sing tobias.sing@gmail.com, Oliver Sander osander@gmail.com

References

A detailed list of references can be found on the ROCR homepage at http://rocr.bioinf.mpi-sb.mpg.de.

See Also


ROCR

Visualizing the Performance of Scoring Classifiers

v1.0-11
GPL (>= 2)
Authors
Tobias Sing [aut], Oliver Sander [aut], Niko Beerenwinkel [aut], Thomas Lengauer [aut], Thomas Unterthiner [ctb], Felix G.M. Ernst [cre] (<https://orcid.org/0000-0001-5064-0928>)
Initial release
2020-05-01

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.