Description Usage Arguments Value Author(s) Examples
View source: R/plotAlphaDistributionOneChr.R
This function calculates the alpha values for a selected chromosome and plots the distribution of alpha values. The shape of the distribution is indicative of the presence or absence of partially methylated domains (PMDs).
1 | plotAlphaDistributionOneChr(m, chr.sel, pdfFilename = NULL, num.cores = 1, nCGbin = 101)
|
m |
Methylation GRanges object. |
chr.sel |
Selected chromosome for which alpha values are calculated. Must be one of the sequence levels of m. |
pdfFilename |
Name of the pdf file in which the figure is saved. If no name is provided (default), the figure is printed to the screen. |
num.cores |
The number of cores that are used for the calculation (default 1). |
nCGbin |
The number of CpGs in each sliding window used to calculate alpha (default 101). The default is highly recommended. |
No return value. The function creates a figure showing the alpha distribution for the selected chromosome that is either printed to the screen (default) or saved as a pdf if a filename is provided.
Lukas Burger lukas.burger@fmi.ch
1 2 3 4 5 6 7 8 9 10 11 12 13 | library(MethylSeekR)
# get chromosome lengths
library("BSgenome.Hsapiens.UCSC.hg18")
sLengths=seqlengths(Hsapiens)
# read methylation data
methFname <- system.file("extdata", "Lister2009_imr90_hg18_chr22.tab",
package="MethylSeekR")
meth.gr <- readMethylome(FileName=methFname, seqLengths=sLengths)
#calculate alpha distribution for one chromosome
plotAlphaDistributionOneChr(m=meth.gr, chr.sel="chr22", num.cores=1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.