addSize {strvalidator}R Documentation

Add Size Information.

Description

Add size information to alleles.

Usage

addSize(data, kit = NA, bins = TRUE, ignore.case = FALSE, debug = FALSE)

Arguments

data

data.frame with at least columns 'Marker' and 'Allele'.

kit

data.frame with columns 'Marker', 'Allele', and 'Size' (for bins=TRUE) or 'Marker', 'Allele', 'Offset' and 'Repeat' (for bins=FALSE).

bins

logical TRUE alleles get size from corresponding bin. If FALSE the size is calculated from the locus offset and repeat unit.

ignore.case

logical TRUE case in marker names are ignored.

debug

logical indicating printing debug information.

Details

Adds a column 'Size' with the fragment size in base pair (bp) for each allele as estimated from kit bins OR calculated from offset and repeat. The bins option return NA for alleles not in bin. The calculate option handles all named alleles including micro variants (e.g. '9.3'). Handles 'X' and 'Y' by replacing them with '1' and '2'.

Value

data.frame with additional columns for added size.


[Package strvalidator version 2.4.1 Index]