Computes different metrics of selection performance from a categorical vector/matrix with 3 for True Positive, 2 for False Negative, 1 for False Positive and 0 for True Negative.
SelectionPerformanceSingle(Asum, cor = NULL, thr = 0.5)
A matrix of selection metrics including:
number of True Positives (TP)
number of False Negatives (TN)
number of False Positives (FP)
number of True Negatives (TN)
sensitivity, i.e. TP/(TP+FN)
specificity, i.e. TN/(TN+FP)
accuracy, i.e. (TP+TN)/(TP+TN+FP+FN)
precision (p), i.e. TP/(TP+FP)
recall (r), i.e. TP/(TP+FN)
F1-score, i.e. 2*p*r/(p+r)
If argument "cor" is provided, the number of False Positives among correlated (FP_c) and uncorrelated (FP_i) pairs, defined as having correlations (provided in "cor") above or below the threshold "thr", are also reported.
vector (in variable selection) or matrix (in graphical modelling)
containing values of 0
, 1
, 2
or 3
.
optional correlation matrix. Only used in graphical modelling.
optional threshold in correlation. Only used in graphical modelling and when argument "cor" is not NULL.