detectionStats: detectionStats

View source: R/detection.R

detectionStatsR Documentation

detectionStats

Description

Given a vector functional (true) attribute names and a vector of positive association attribute names, returns detection statistics like recall and precision. Note you must include the number of variables if you want to compute TN and MCC.

Usage

detectionStats(functional, positives, num_all_vars = NULL)

Arguments

functional

character vector of functional/true attribute names.

positives

character vector of attribute names of positive associations (null hypothesis rejected or some threshold).

num_all_vars

total number of variables, needed for TN calculation for MCC

Value

list with elements TP, FP, FN, TPR, FPR, precision, recall, F1, MCC, and summary message (string).

Examples

functional <- c("var1", "var2", "var3")
detected <- c("var1", "var2", "var4")
detectionStats(functional, detected)

insilico/npdr documentation built on July 6, 2023, 1:14 p.m.