analyseReadsInsideRegionsForCondition: Analyse reads inside regions for condition

Description Usage Arguments Value Author(s) See Also Examples

View source: R/computeDMRs.R

Description

This function extracts from the methylation data the total number of reads, the number of methylated reads and the number of cytosines in the specific context from a region (e.g. DMRs)

Usage

1
2
analyseReadsInsideRegionsForCondition(regions, methylationData, context,
  label = "", cores = 1)

Arguments

regions

a GRanges object with a list of regions on the genome; e.g. could be a list of DMRs

methylationData

the methylation data in one condition (see methylationDataList).

context

the context in which to extract the reads ("CG", "CHG" or "CHH").

label

a string to be added to the columns to identify the condition

cores

the number of cores used to compute the DMRs.

Value

a GRanges object with additional four metadata columns

sumReadsM

the number of methylated reads

sumReadsN

the total number of reads

proportion

the proportion methylated reads

cytosinesCount

the number of cytosines in the regions

Author(s)

Nicolae Radu Zabet

See Also

filterDMRs, computeDMRs, DMRsNoiseFilterCG, and mergeDMRsIteratively

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
# load the methylation data
data(methylationDataList)

#load the DMRs in CG context. These DMRs were computed with minGap = 200.
data(DMRsNoiseFilterCG)

#retrive the number of reads in CHH context in WT
DMRsNoiseFilterCGreadsCHH <- analyseReadsInsideRegionsForCondition(
                             DMRsNoiseFilterCG[1:10],
                             methylationDataList[["WT"]], context = "CHH",
                             label = "WT")

DMRcaller documentation built on Nov. 8, 2020, 5:26 p.m.