fraction.target: Fraction of the target within the genome

Description Usage Arguments Value Note Author(s) See Also Examples

View source: R/fraction.target.R

Description

Calculates the fraction of the reference genome that is targeted

Usage

1
fraction.target(targets, Offset = 0, genome = c(NA, "hg38", "hg19", "hg18"), genomesize)

Arguments

targets

RangedData table containing positions of target regions, i.e. output from get.targets

Offset

integer; add Offset bases on both sides to targeted regions and potentially collapse resulting overlapping target regions

genome

genome version targets were designed and reads aligned to. For the given options the total genome size is set automatically. For other genomes or versions, leave this option empty ('NA') and specify the genome size with option 'genomesize'

genomesize

integer: specify the total genome size manually. If 'genomesize' is given, option 'genome' will be ignored.

Value

Returns the fraction of nucleotides within the genome that were targeted.

Note

With the output from fraction.target and fraction.reads.target the 'enrichment' of the target capture experiment can be calculated as 'fraction of on-target reads / fraction of target within genome'

Author(s)

Manuela Hummel m.hummel@dkfz.de

See Also

fraction.reads.target, get.targets

Examples

1
2
3
4
exptPath <- system.file("extdata", package="TEQC")
targetsfile <- file.path(exptPath, "ExampleSet_Targets.bed")
targets <- get.targets(targetsfile, skip=0)
fraction.target(targets, genome="hg19")

hummelma/TEQC documentation built on March 22, 2021, 9:45 a.m.