qaVariants {VariantTools} | R Documentation

## QA Filtering of Variants

### Description

Filters a tally `GRanges` through a series of simple checks for strand and read position (read position) biases.

### Usage

    qaVariants(x, qa.filters = VariantQAFilters(...), ...)
    VariantQAFilters(fisher.strand.p.value = 1e-4, min.mdfne = 10L)

### Arguments

`x` | A tally `GRanges` as output by `tallyVariants`.
`qa.filters` | The filters used for the QA process, typically constructed with `VariantQAFilters`, see arguments below.
`...` | Arguments passed to `VariantQAFilters`, listed below.
`fisher.strand.p.value` | p-value cutoff for the Fisher's Exact Test for strand bias (+/- counts, alt vs. ref). Any variants with p-values below this cutoff are discarded.
`min.mdfne` | Minimum allowed median distance of alt calls from their nearest end of the read.

### Details

There are currently two QA filters:

- Median distance of alt calls from nearest end of the read is required to be >= `min.mdfne`, which defaults to 10.

- Fisher's Exact Test for strand bias, using the +/- counts, alt vs. ref. If the null is rejected, the variant is discarded.

### Value

For `qaVariants`, a tally `GRanges` of the variants that pass the QA checks.

For `VariantQAFilters`, a `FilterRules` object with the QA and sanity filters.

### Author(s)

Michael Lawrence and Jeremiah Degenhardt

### Examples

    data(vignette)
    qaVariants(tallies_H1993, fisher.strand.p.value = 1e-4)

[Package VariantTools version 1.26.0 Index]