sim_find_tp: This function finds the number of true positives when...

View source: R/sim_find_tp.R

sim_find_tpR Documentation

This function finds the number of true positives when comparing two sets of recombination breakpoints

Description

This function finds the number of true positives by finding the number of true recombinantion breakpoints which are intersected by a rhapsodi predicted recombination breakpoint. In liberal mode (default), every single intersection is counted as a true positive, even if a single predicted breakpoint intersects multiple true breakpoints. In the conservative mode, we only count one of these multiple intersections as a true positive. If there are no non-NA truths or no non-NA predictions, there are 0 true positives

Usage

sim_find_tp(
  truth_intersect_dt,
  cons = FALSE,
  no_truths = FALSE,
  no_preds = FALSE
)

Arguments

truth_intersect_dt

a data table from foverlaps intersecting the truth and the predicted data with columns gam, Predicted_Start, Predicted_End, True_Start, True_End

cons

a bool, default is FALSE; only applicable when multiple predictions intersect a single truth. If cons is TRUE, we take a conservative approach and for each multiple intersection, we consider only one of these breakpoints as a true positive

no_truths

a bool, default is FALSE. If TRUE, that means there were only NAs in the truth information and no real recombination break points

no_preds

a bool, default is FALSE. If TRUE, that means there were only NAs in the prediction information from rhapsodi and no predicted recombination break points


mccoy-lab/rhapsodi documentation built on July 27, 2022, 3:56 a.m.