plotOverlapProfile {DMRcaller} | R Documentation |
This function plots the distribution of a set of subregions on a large region.
plotOverlapProfile(overlapsProfiles1, overlapsProfiles2 = NULL, names = NULL, labels = NULL, col = NULL, title = "", logscale = FALSE, maxValue = NULL)
overlapsProfiles1 |
a |
overlapsProfiles2 |
a |
names |
a |
labels |
a |
col |
a |
title |
the title of the plot. |
logscale |
a |
maxValue |
a maximum value in a region. Used for the colour scheme. |
Invisibly returns NULL
.
Nicolae Radu Zabet
computeOverlapProfile
, filterDMRs
,
computeDMRs
and mergeDMRsIteratively
# load the methylation data data(methylationDataList) # load the DMRs in CG context data(DMRsNoiseFilterCG) # the coordinates of the area to be plotted largeRegion <- GRanges(seqnames = Rle("Chr3"), ranges = IRanges(1,1E5)) # compute overlaps distribution hotspotsHypo <- computeOverlapProfile(DMRsNoiseFilterCG, largeRegion, windowSize = 10000, binary = FALSE) plotOverlapProfile(GRangesList("Chr3"=hotspotsHypo), names = c("hypomethylated"), title = "CG methylation") ## Not run: largeRegion <- GRanges(seqnames = Rle("Chr3"), ranges = IRanges(1,1E6)) hotspotsHypo <- computeOverlapProfile( DMRsNoiseFilterCG[(DMRsNoiseFilterCG$regionType == "loss")], largeRegion, windowSize=2000, binary=TRUE, cores=1) hotspotsHyper <- computeOverlapProfile( DMRsNoiseFilterCG[(DMRsNoiseFilterCG$regionType == "gain")], largeRegion, windowSize=2000, binary=TRUE, cores=1) plotOverlapProfile(GRangesList("Chr3"=hotspotsHypo), GRangesList("Chr3"=hotspotsHyper), names=c("loss", "gain"), title="CG methylation") ## End(Not run)