showOneDMR: Visualze the count data for one DMR

Description Usage Arguments Value Author(s) See Also Examples

View source: R/BSseq_plots.R

Description

Given one DMR and an BSseq object, this function generate a multiple panel figure, each for a sample, to visualze the counts. There is a bar at each CpG, the gray bar shows the total coverage, and the black bar shows the methylated count.

Usage

1
showOneDMR(OneDMR, BSobj, ext = 500, ylim)

Arguments

OneDMR

A data frame with one row representing one DMR. It must have chr, start, and end columns. This is typically a row from the result generated from callDMR.

BSobj

An object of class BSseq.

ext

The amount (in bps) the plotting region should be extended in both directions.

ylim

Y-axis limit.

Value

This function only generates a figure and has no return values.

Author(s)

Hao Wu <hao.wu@emory.edu>

See Also

callDMR

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
## Not run: 
require(bsseq)
require(bsseqData)
data(BS.cancer.ex)

## takea small portion of data and test
BSobj <- BS.cancer.ex[140000:150000,]
dmlTest <- DMLtest(BSobj, group1=c("C1", "C2", "C3"), group2=c("N1","N2","N3"),
   smoothing=TRUE, smoothing.span=500)

## call DMR based on test results
dmrs <- callDMR(dmlTest)

## visualize one DMR
showOneDMR(dmrs[1,], BSobj)

## End(Not run)

DSS documentation built on Nov. 8, 2020, 7:44 p.m.