get_coverage_bed: Get coverage for target regions

Description Usage Arguments Value

View source: R/coverage.R

Description

This function takes a BAM and a BED file with target regions and estimate per base coverage for them using samtools depth

Usage

1
2
3
4
5
6
7
8
get_coverage_bed(
  bin_path = "tools/samtools/samtools",
  bam = "",
  bed = "",
  mapq = 0,
  threads = 3,
  output_dir = ""
)

Arguments

bin_path

Path to samtools. Default tools/samtools/samtools

bam

Path to BAM file

bed

Path to BED file

mapq

Minimum mapping quality

threads

Number of threads to use. Default 3

output_dir

Directory to output results

Value

A double with the mean genome coverage


TearsWillFall/tfProfiling documentation built on Aug. 7, 2021, 9:40 a.m.