def runDESeq( infiles, outfile ): '''estimate differential expression using DESeq. The final output is a table. It is slightly edited such that it contains a similar output and similar fdr compared to cuffdiff. ''' PipelineWindows.runDE( infiles, outfile, "deseq.dir", method = "deseq" )
def countReadsWithinWindows(infiles, outfile ): '''build read counds for windows.''' bedfile, windowfile = infiles PipelineWindows.countReadsWithinWindows( bedfile, windowfile, outfile, counting_method = PARAMS['tiling_counting_method'] )
def runEdgeR( infiles, outfile ): '''estimate differential methylation using EdgeR This method applies a paired test. The analysis follows the example in chapter 11 of the EdgeR manual. ''' PipelineWindows.runDE( infiles, outfile, "edger.dir", method = "edger" )
def aggregateWindowsReadCounts( infiles, outfile ): '''aggregate tag counts for each window. coverageBed outputs the following columns: 1) Contig 2) Start 3) Stop 4) Name 5) The number of features in A that overlapped (by at least one base pair) the B interval. 6) The number of bases in B that had non-zero coverage from features in A. 7) The length of the entry in B. 8) The fraction of bases in B that had non-zero coverage from features in A. For bed: use column 5 For bed6: use column 7 For bed12: use column 13 Tiles with no counts will not be output. ''' PipelineWindows.aggregateWindowsReadCounts( infiles, outfile )
def outputAllWindows( infile, outfile ): '''output all bed windows.''' PipelineWindows.outputAllWindows( infile, outfile )
def buildDMRStats( infile, outfile ): '''compute differential methylation stats.''' method = os.path.dirname(infile) method = P.snip( method, ".dir") PipelineWindows.buildDMRStats( infile, outfile, method=method )
def runFilterAnalysis( infiles, outfile ): '''output windows applying a filtering criterion. Does not apply a threshold. ''' PipelineWindows.outputRegionsOfInterest( infiles, outfile )
def aggregateWindowsReadCounts( infiles, outfile ): '''aggregate tag counts for each window. ''' PipelineWindows.aggregateWindowsReadCounts( infiles, outfile )
def loadContextStats(infiles, outfile): ''' load context mapping statistics into context_stats table ''' PipelineWindows.loadSummarizedContextStats(infiles, outfile)
def buildContextStats(infiles, outfile): ''' build mapping context stats ''' PipelineWindows.summarizeTagsWithinContext( infiles[0], infiles[1], outfile)