markDuplicates.Rd
markDuplicates
Mark duplicated reads from a BAM file by calling
widely used tools.
The tool to be called. Currently, "picard" and "bamutils" are supported
The bam file to mark duplicates from
Regular expression describing the transformation on the original filename to get the output filename. By default, a "_duprm" suffix is added before the bam extension
Whether to keep the original, non duplicate-marked, bam file
Path to the duplicate marker binaries
Redirect all the program output to the R console
Other parameters sent to the caller function
The output filename
This function works as a wrapper for several tools widely adopted tr mark duplicated reads in a BAM file. Currently, it supports PICARD and BamUtils.
if (FALSE) {
bam <- system.file("extdata","sample1Aligned.out.bam",package="dupRadar")
gtf <- "genes.gtf"
stranded <- 2 # '0' (unstranded), '1' (stranded) and '2' (reverse)
paired <- FALSE
threads <- 4
# call the duplicate marker and analyze the reads
bamDuprm <- markDuplicates(dupremover="bamutil",bam,
path="/opt/bamUtil-master/bin",rminput=FALSE)
dm <- analyzeDuprates(bamDuprm,gtf,stranded,paired,threads)
}