variantGCContent: Calculate GC content in window around a set of variants

Description Usage Arguments Value Examples

Description

Calculate GC content in window around a set of variants

Usage

1
variantGCContent(vcf, fasta, windowSize = 100)

Arguments

vcf

A VCF-class object

fasta

A FaFile object

windowSize

An integer representing the window size around each variant to calculate GC content

Value

A numeric vector giving the GC content for each variant window in the input

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 
require(VariantAnnotation)
require(AnnotationHub)
fl <- system.file("extdata", "chr22.vcf.gz", package="VariantAnnotation")
param <- ScanVcfParam(fixed="ALT", geno=c("GT", "GL"), info=c("LDAF"))
vcf = readVcf(fl,"hg19",param=param)
ah = AnnotationHub()
hg19fa = ah$ensembl.release.72.fasta.homo_sapiens.dna.Homo_sapiens.GRCh37.72.dna.toplevel.fa.rz
varGC = variantGCContent(vcf,hg19fa)
plot(density(varGC))

## End(Not run)

seandavi/MutationTools documentation built on May 29, 2019, 4:32 p.m.