Description Usage Arguments Value Author(s) Examples
View source: R/coverageFromBedGraph.R
read coverage from bedGraph files and save as a list.
1 2 | coverageFromBedGraph(bedgraphs, tags, genome,
hugeData=FALSE, BPPARAM=NULL, ...)
|
bedgraphs |
The file names of bedgraphs generated by bedtools. eg: bedtools genomecov -bg -split -ibam $bam -g mm10.size.txt > $bedgraph |
tags |
the names for each input bedgraphs |
genome |
an object of BSgenome |
hugeData |
is this dataset consume too much memory? if it is TRUE, the coverage will be saved into tempfiles. |
BPPARAM |
An optional |
... |
parameters can be passed into tempfile. This is useful when you submit huge dataset to cluster. |
return a list of coverage for each bedgraph files. For each item in the list, it is a list of coverage for each chromosome. And the chromosome must start from "chr".
Jianhong Ou
1 2 3 4 5 6 7 8 9 10 | if(interactive()){
library(BSgenome.Mmusculus.UCSC.mm10)
path <- file.path(find.package("InPAS"), "extdata")
bedgraphs <- file.path(path, "Baf3.extract.bedgraph")
data(utr3.mm10)
tags <- "Baf3"
genome <- BSgenome.Mmusculus.UCSC.mm10
coverage <-
coverageFromBedGraph(bedgraphs, tags, genome, hugeData=FALSE)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.