lindenb / jvarkit

Java utilities for Bioinformatics
https://jvarkit.readthedocs.io/
Other
482 stars 133 forks source link

MIN_COVERAGE doesn't seem to work #52

Closed hamidhamzeiy closed 8 years ago

hamidhamzeiy commented 8 years ago

java version "1.8.0_91" - Ubuntu 14.04

MIN_COVERAGE doesn't seem to work

When I give a BAM file as input along with a BED file with my regions of interest and choose MIN_COVERAGE as 5, I still get results with min of 0.

lindenb commented 8 years ago

which tool ? what is your command line ?

hamidhamzeiy commented 8 years ago

Sorry, here it is:

java -jar bamstats04.jar BED='path' I='path' MIN_COVERAGE=5 >'result.txt'

hamidhamzeiy commented 8 years ago

chrom start end length mincov maxcov mean nocoveragepb percentcovered

chr1 66999065 67210057 210992 0 980 17.1119995071 167596 20

lindenb commented 8 years ago

Ah, I see.

The min coverage in chr1 66999065 67210057 is zero = there are some bases that were not covered, and you cannot do anything about it. But the fields/columns nocoveragepb percentcovered take into account the parameters MIN_COVERAGE. If a position is covered less than MIN_COVERAGE then this position is considered as not coverage

hamidhamzeiy commented 8 years ago

Thank you so much for the quick reply. It was very helpful :)