enrichmentMatrix {genomation} | R Documentation |
This is an enrichmentMatrix
function for ScoreMatrix
objects,
that enables to normalize ChIP-seq signals with respect to IgG or input DNA control.
\S4method{enrichmentMatrix}{ScoreMatrix,ScoreMatrix}(IP, control)
IP |
|
control |
|
ScoreMatrix
object
The function computes an enrichment of IP over control as follow: Suppose both IP and control are ScoreMatrix objects that have same dimensions. Then, the enrichment is calculated usign a formula: log2((IP + 1) / (control + 1)).
#load IP and control BAM files and create ScoreMatrix objects library('genomationData') bam.file_IP <- system.file("extdata", "wgEncodeBroadHistoneH1hescSuz12051317AlnRep1.chr21.bam", package = "genomationData") bam.file_c <- system.file("extdata", "wgEncodeBroadHistoneH1hescCtcfStdAlnRep1.chr21.bam", package = "genomationData") data(promoters) IP <- ScoreMatrix(target = bam.file_IP, windows = promoters, type = 'bam') control <- ScoreMatrix(target = bam.file_c, windows = promoters, type = 'bam') # compute an enrichment of IP over control enrichmentMatrix(IP, control)