Entering edit mode
2.7 years ago
junnna
▴
10
Hi,
I would like to filter out regions with >50x coverage from a pacbio hifi bamfile such that the resulting filtered bam file has zero coverage in those regions.
I tried variantbam https://github.com/walaj/VariantBam, like so:
variant $bam -m 100 -o mini.bam -b
but this gives me an error:
removeElem: elem of value -1 is below min bin 0,0,0
Any ideas would be greatly appreciated!
Thanks in advance
Is your BAM file sorted? Are you actually substituting the name of your BAM file in place of
$bam
?Additional options:
https://ngsutils.org/modules/bamutils/extract/ (use an inverted BED file to select regions you want to keep).