plotDinuclFreq: Plot dinuclotide content within region set(s)

View source: R/content-plots.R

plotDinuclFreqR Documentation

Plot dinuclotide content within region set(s)

Description

Given calcDinuclFreq or calcDinuclFreqRef results, this function generates a violin plot of dinucleotide frequency

Usage

plotDinuclFreq(DNFDataTable)

Arguments

DNFDataTable

A data.table, data.frame, or a list of dinucleotide counts - results from calcDinuclFreq or calcDinuclFreqRef

Value

A ggplot object plotting distribution of dinucleotide content in query regions

Examples


DNFDataTable = data.table::data.table(GC = rnorm(400, mean=0.5, sd=0.1), 
CG = rnorm(400, mean=0.5, sd=0.5), 
AT = rnorm(400, mean=0.5, sd=1), 
TA = rnorm(400, mean=0.5, sd=1.5))
DNFPlot =  plotDinuclFreq(DNFDataTable)

## Not run: 
query = system.file("extdata", "vistaEnhancers.bed.gz", package="GenomicDistributions")
GRquery = rtracklayer::import(query)
refAssembly = 'hg19'
DNF = calcDinuclFreqRef(GRquery, refAssembly)
DNFPlot2 =  plotDinuclFreq(DNF)

## End(Not run) 

databio/GenomicDistributions documentation built on April 30, 2024, 4:34 a.m.