Skip to contents

False discovery rate, c, is defined as: FP/(FP+TP), where FP is the number of false-positives and TP is the number of true positives (https://en.wikipedia.org/wiki/Precision_and_recall; TODO: find a primary literature citation to use instead of citing wikipedia).

Usage

falseDiscoveryRate(
  ch,
  season = "year",
  snrTruncationThreshold = NULL,
  gtColName = "detect_table1",
  testColName = "detect_table2",
  snrColName = "SNR"
)

Arguments

ch

data.frame with capture history table

season

a character indicating the season or month for which to estimate call density

snrTruncationThreshold
  • Exclude rows with SNR below this threshold (in dB)

gtColName

Column in ch treated as ground truth (0/1 or logical).

testColName

Column(s) in ch for the detector(s) under evaluation. A single column name (default) computes the false discovery rate for that one detector, as always. A vector of column names computes it for the union of those detectors instead – flagged positive if any of them is – matching the union detection probability a whichObserver = "any" vglm model already gives via pDetInArea. Same "vector means combine" convention already used for signalCol/noiseCol in chtToSNRinfo and yColNames in fitDetFun.

snrColName

Column in ch holding SNR, used only if snrTruncationThreshold is set.

Value

fdr, list containing false disovery rate, c, and it's CV. The false discovery rate c, is equal to (1-precision) for detector2 assuming detector1 is ground truth for detections within the specified season

Details

Here we estimate false-positive rate of the automated detector from the manually annotated dataset. The data-file for this is the capture-history table that contains reconciled annotated, and automated detections.

First, we count the number of FP that the detector produced from the capture history table. These are the sum of the rows where detect_table2==T & detect_table1==F. Then we calculate the number of true positives, the sum of the rows where detect_table2==T & detect_table1==T.