swGenotype: Call markers based on allelic imbalance.

Description Usage Arguments Details Value

Description

swGenotype Takes a 2-dimensional dataset (markers x libraries) with the proportion of reference allele calls (for bi-allelic markers) and returns a matrix of genotype calls across a specified sliding window width. Requires 'zoo' to do the sliding window.

Usage

1
2
3
swGenotype(reference.prop, chr, pos, marker.id, width = 20,
  prop2call = 0.95, plot.diagnostics = FALSE, verbose = TRUE,
  calcMeans = TRUE, makeSoftCalls = TRUE, makeHardCalls = TRUE)

Arguments

reference.prop

The dataset containing ratios of reads to reference genotype. All data must be numeric.

chr

A vector (matching rows in reference.prop) with the chromosome identifier

pos

A vector (matching rows in reference.prop) with the marker position

marker.id

A vector (matching rows in reference.prop) with the marker identifier

width

The width of the window within which calls are made.

prop2call

The threshold of majority voting to make soft calls. If the proportion of genotypes in agreement are < prop2call, NA is returned

plot.diagnostics

Should histograms of reference.prop be returned for each library. Helps to look at this if you are concerned about a few library's quality

verbose

Should updates be printed?

calcMeans

Should mean values for each window be returned? Helps with diagnostics.

makeSoftCalls

Should soft-calls be made? See prop2call.

makeHardCalls

Should hard-calls be made? Hard calls are the majority vote for each window, disregarding prop2call.

Details

The approach operates library-by-library and ignores among library correlations. For each library, prior thresholds for each genotype are calculated based on the least common observed ratio above 60 betweent these thresholds are initially called as A/B (0.5), below the threshold are A/A (0.0) and above the upper threshold is B/B (1.0). Given these initial calls, a sliding window is applied counting the proportion of each. Mean, soft- and hard-calls are made within each window

Value

A list containing the desired output.


jtlovell/qtlTools documentation built on May 20, 2019, 3:14 a.m.