Description Usage Arguments Details Value Author(s) See Also Examples
Calculate fraction of reference allele reads
1 2 3 4 5 6 |
gdsobj |
A |
FUN |
The function to apply over heterozygote calls (mean or median). |
use.names |
A logical indicating whether to assign variant or samples IDs as names of the output vector. |
parallel |
Logical, numeric, or other value to control parallel
processing; see |
variant.id |
A vector of variant.ids to plot. |
highlight |
A list of sample.ids to highlight with sequential integers on each plot |
... |
Additional arguments passed to |
The variable "annotation/format/AD" (allelic depth) is required to compute the reference allele fraction.
refFracPlot
generates plots of total unfiltered depth (sum over "AD" for
all alleles) versus reference allele fraction. Points are color-coded
by called genotype: teal = reference homozygote, orange = heterozygote
including the reference allele, fuschia = heterozygote with two
alternate alleles, purple = alternate homozygote, black = missing.
Darker colors indicate a higher density of points.
Vertical black line
is at 0.5, vertical orange line is the median reference allele fraction
for ref/alt heterozygotes. Values significantly different from 0.5
(after applying a Bonferroni correction) are plotted with triangles.
refFrac
returns a sample by variant array of the reference allele
fraction, defined as ref_depth / total_depth.
refFracOverHets
returns the mean (or other function,
e.g. median) of reference allele
depth (per variant) over all samples called as heterozygotes.
Stephanie Gogarten
1 2 3 4 5 6 7 8 | gdsfile <- system.file("extdata", "hapmap_exome_chr22.gds", package="SeqVarTools")
gds <- seqOpen(gdsfile)
RF <- refFrac(gds)
dim(RF)
samples <- seqGetData(gds, "sample.id")
refFracPlot(gds, variant.id=5:6,
highlight=list(samples[2:3], samples[4:5]))
seqClose(gds)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.