bedtools multicov, reports the count of alignments from multiple position-sorted and indexed BAM files that overlap intervals in a BED file. Specifically, for each BED interval provided, it reports a separate count of overlapping alignments from each BAM file.
multiBamCov [OPTIONS] -bams BAM1 BAM2 BAM3 ... BAMn -bed
-split Treat “split†BAM or BED12 entries as distinct BED intervals.
-s Require same strandedness. That is, only report hits in B
that overlap A on the _same_ strand. By default, overlaps are
reported without respect to strand.
-S Require different strandedness. That is, only report hits in B
that overlap A on the _opposite_ strand. By default, overlaps
are reported without respect to strand.
-f Minimum overlap required as a fraction of each A. Default is
1E-9 (i.e., 1bp).
-r Require that the fraction overlap be reciprocal for A and B. In
other words, if -f is 0.90 and -r is used, this requires that
B overlap 90% of A and A _also_ overlaps 90% of B.
-q Minimum mapping quality (MAPQ) allowed. Default is 0.
-D Include duplicate reads. Default counts non-duplicates only
-F Include failed-QC reads. Default counts pass-QC reads only
-p Only count proper pairs. Default counts all alignments with
MAPQ > -q
argument, regardless of the BAM FLAG field.