walaj / VariantBam

Filtering and profiling of next-generational sequencing data using region-specific rules
Other
74 stars 10 forks source link

variant command overestimates max coverage with Nanopore reads #22

Open pmaragno opened 1 year ago

pmaragno commented 1 year ago

Dear VariantBam developers,

I ran the command variant $bam -m 100 -o mini.bam -b to obtain a maximum coverage of 50 along my sample, however when I visually inspected the result in the genome browser I noticed that the maximum coverage is higher than 50, as visible in the picture:

VariantBam_example_50X

Maybe, this bug could be due to the fact that Nanopore reads are not all of the same length, unlike Illumina reads?

Thanks in advance, Paola Maragno

walaj commented 1 year ago

Doesn't the command with -m 100 set max coverage to 100, not 50?

pmaragno commented 1 year ago

Sorry, I reported that command as an example, but I set -m to 50 to obtain a maximum coverage of 50 along my sample.

walaj commented 1 year ago

OK hard to say -- the issue must be somewhere in STCoverage (https://github.com/walaj/VariantBam/blob/master/src/STCoverage.cpp). I can try to re-create and fix if you have the ability to share a minimal BAM fragment (e.g. with a Dropbox link, can send to jwala@broadinstitute.org)

pmaragno commented 1 year ago

I have just shared with you by mail (paola.maragno@iit.it) the bam file. Thanks for the help!

mbhall88 commented 7 months ago

Were you ever able to get to the bottom of this @walaj?