context("calculating coverage in reads per million")
test_that("test coverage.rpm on GRanges", {
data("nucleosome_htseq")
cov.sum <- sum(coverage.rpm(nucleosome_htseq))
expect_equal(cov.sum, c(chr1=175075607))
})
test_that("test coverage.rpm on IRanges", {
data("nucleosome_htseq")
ir <- ranges(nucleosome_htseq)
cov.sum <- sum(coverage.rpm(ir))
expect_equal(cov.sum, 175075607)
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.