p.adjust.
addNBSignificance(x, estimate="NB.012", correct = "none", max.n=10L)data.frame of class slidingWindowSummary, as
returned by the function perWindow.p.adjust including
none if no correction is desired.estimate=="NB.ML"; in
that case specifies that windows with up to this number of aligned
reads should be considered for estimating the background
distribution.data.frame of class slidingWindowSummary, which is the
the supplied argument x extended by an additional column
p.value which holds the p-value for each window.
The attribute NBparams of the result contains the list of the
estimated parameters of the Negative-Binomial background
distribution.
The function knows a number of methods to estimate the parameters of the NB distribution.
fitdistr from package MASS. Windows with up to
n.max aligned reads are considered for this estimate.
perWindow, p.adjust
exDir <- system.file("extdata", package="girafe")
exA <- readAligned(dirPath=exDir, type="Bowtie",
pattern="aravinSRNA_23_no_adapter_excerpt_mm9_unmasked.bwtmap")
exAI <- as(exA, "AlignedGenomeIntervals")
exPX <- perWindow(exAI, chr="chrX", winsize=1e5, step=0.5e5)
exPX <- addNBSignificance(exPX, correct="bonferroni")
str(exPX)
exPX[exPX$p.value <= 0.05,]
Run the code above in your browser using DataLab