calculateAllele {strvalidator} | R Documentation |
Calculate Allele
Description
Calculates summary statistics for alleles per marker over the entire dataset.
Usage
calculateAllele(
data,
threshold = NULL,
sex.rm = FALSE,
kit = NULL,
debug = FALSE
)
Arguments
data |
data.frame including columns 'Marker' and 'Allele', and optionally 'Height' and 'Size'. |
threshold |
numeric if not NULL only peak heights above 'threshold' will be considered. |
sex.rm |
logical TRUE removes all sex markers. Requires 'kit'. |
kit |
character for the DNA typing kit defining the sex markers. |
debug |
logical indicating printing debug information. |
Details
Creates a table of the alleles in the dataset sorted by number of observations.For each allele the proportion of total observations is calculated. Using a threshold this can be used to separate likely artefacts from likely drop-in peaks. In addition the observed allele frequency is calculated. If columns 'Height' and/or 'Size' are available summary statistics is calculated. NB! The function removes NA's and OL's prior to analysis.
Value
data.frame with columns 'Marker', 'Allele', 'Peaks', 'Size.Min', 'Size.Mean', 'Size.Max', 'Height.Min', 'Height.Mean', 'Height.Max', 'Total.Peaks', 'Allele.Proportion', 'Sum.Peaks', and 'Allele.Frequency'.