calculateAT: Calculate Analytical Threshold

View source: R/calculateAT.r

calculateATR Documentation

Calculate Analytical Threshold

Description

Calculate analytical thresholds estimates.

Usage

calculateAT(
  data,
  ref = NULL,
  mask.height = TRUE,
  height = 500,
  mask.sample = TRUE,
  per.dye = TRUE,
  range.sample = 20,
  mask.ils = TRUE,
  range.ils = 10,
  k = 3,
  rank.t = 0.99,
  alpha = 0.01,
  ignore.case = TRUE,
  word = FALSE,
  debug = FALSE
)

Arguments

data

a data frame containing at least 'Dye.Sample.Peak', 'Sample.File.Name', 'Marker', 'Allele', 'Height', and 'Data.Point'.

ref

a data frame containing at least 'Sample.Name', 'Marker', 'Allele'.

mask.height

logical to indicate if high peaks should be masked.

height

integer for global lower peak height threshold for peaks to be excluded from the analysis. Active if 'mask.peak=TRUE.

mask.sample

logical to indicate if sample allelic peaks should be masked.

per.dye

logical TRUE if sample peaks should be masked per dye channel. FALSE if sample peaks should be masked globally across dye channels.

range.sample

integer to specify the masking range in (+/-) data points. Active if mask.sample=TRUE.

mask.ils

logical to indicate if internal lane standard peaks should be masked.

range.ils

integer to specify the masking range in (+/-) data points. Active if mask.ils=TRUE.

k

numeric factor for the desired confidence level (method AT1).

rank.t

numeric percentile rank threshold (method AT2).

alpha

numeric one-sided confidence interval to obtain the critical value from the t-distribution (method AT4).

ignore.case

logical to indicate if sample matching should ignore case.

word

logical to indicate if word boundaries should be added before sample matching.

debug

logical to indicate if debug information should be printed.

Details

Calculate the analytical threshold (AT) according to method 1, 2, and 4 as recommended in the reference by analyzing the background signal (noise). In addition method 7, a log-normal version of method 1 has been implemented. Method 1: The average signal + 'k' * the standard deviation. Method 2: The percentile rank method. The percentage of noise peaks below 'rank.t'. Method 4: Utilize the mean and standard deviation and the critical value obtained from the t-distribution for confidence interval 'alpha' (one-sided) and observed peaks analyzed (i.e. not masked) minus one as degrees of freedom, and the number of samples. Method 7: The average natural logarithm of the signal + k * the standard deviation.

If samples containing DNA are used, a range around the allelic peaks can be masked from the analysis to discard peaks higher than the noise. Masking can be within each dye or across all dye channels. Similarly a range around the peaks of the internal lane standard (ILS) can be masked across all dye channels. Which can bleed-through in week samples (i.e. negative controls) The mean, standard deviation, and number of peaks are calculated per dye per sample, per sample, globally across all samples, and globally across all samples per dye, for each method to estimate AT. Also the complete percentile rank list is calculated.

Value

list of three data frames. The first with result per dye per sample, per sample, globally across all samples, and globally across all samples per dye, for each method. The second is the complete percentile rank list. The third is the masked raw data used for calculation to enable manual check of the result.

References

J. Bregu et.al., Analytical thresholds and sensitivity: establishing RFU thresholds for forensic DNA analysis, J. Forensic Sci. 58 (1) (2013) 120-129, ISSN 1556-4029, DOI: 10.1111/1556-4029.12008. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1111/1556-4029.12008")}

See Also

maskAT, checkSubset


OskarHansson/strvalidator documentation built on July 22, 2023, 12:04 p.m.