Skip to content

sparse bw error in rsamtools summary #100

@shaorray

Description

@shaorray

rtracklayer::summary(BigWigFile(file)) is convenient for extracting interval density, but it's not bullet proof.

It gives error counts when there is empty coverage in the bw file.

For example, if load these intervals:

gene_mm9_chr1_bed <- "gene.mm9.chr1.bed"

toy_bw_file <- "GSE48895_V6.5_untreated_Plus.chr1.bw"

gene_res <- bw_bed(bwfiles = toy_bw_file, bedfile = gene_mm9_chr1_bed)

There are errors Failed to summarize range 194 (chr1:145487827-145497067)Failed to summarize range 231 (chr1:173144101-173149324)Failed to summarize range 265 (chr1:182981368-182990798)Failed to summarize range 303 (chr1:18241059-18255219)Failed to summarize range 311 (chr1:32600391-32604138)Failed to summarize range 368 (chr1:65146963-65149937)Failed to summarize range 431 (chr1:121804478-121809745)

The most trickiest is that it doesn't fill the empty intervals with 0s, but NAs. And half empty intervals also have wrong density counts.
example.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions