PeakQC {esATAC} | R Documentation

## Quality control for peak overlap

### Description

These functions are used to calculate the overlap ratio in specific quality control rigion. Blacklist and DHS region are provided. You can also set your own BED file as quality control rigion.

### Usage

    atacPeakQC(atacProc, bsgenome = NULL, reportOutput = NULL,
      qcbedInput = c("DHS", "blacklist", "path/to/bed"), bedInput = NULL, ...)

    ## S4 method for signature 'ATACProc'
    atacPeakQC(atacProc, bsgenome = NULL,
      reportOutput = NULL, qcbedInput = c("DHS", "blacklist", "path/to/bed"),
      bedInput = NULL, ...)

    peakQC(bedInput, bsgenome = NULL, reportOutput = NULL,
      qcbedInput = c("DHS", "blacklist", "path/to/bed"), ...)

### Arguments

`atacProc` | `ATACProc-class` object scalar. It has to be the return value of upstream process: `atacSamToBed`, `atacBedUtils`.
`bsgenome` | `BSGenome` object scalar. BSGenome object for specific species.
`reportOutput` | `Character` scalar. The report file path.
`qcbedInput` | `Character` scalar. It can be "DHS","blacklist" or Other quality control BED file input path.
`bedInput` | `Character` scalar. BED file input path for quality control.
`...` | Additional arguments, currently unused.

### Details

The parameter related to input and output file path will be automatically obtained from `ATACProc-class` object or generated based on known parameters if their values are default(e.g. `NULL`). Otherwise, the generated values will be overwrited. If you want to use this function independently, you can use `peakQC` instead.

### Value

An invisible `ATACProc-class` object scalar for downstream analysis.

### Author(s)

Zheng Wei

### See Also

`atacSamToBed` `atacBedUtils`

### Examples

    library(R.utils)
    library(magrittr)
    td <- tempdir()
    options(atacConf=setConfigure("tmpdir",td))

    bedbzfile <- system.file(package="esATAC", "extdata", "chr20.50000.bed.bz2")
    bedfile <- file.path(td,"chr20.50000.bed")
    bunzip2(bedbzfile,destname=bedfile,overwrite=TRUE,remove=FALSE)
    blacklistfile <- system.file(package="esATAC", "extdata", "hg19.blacklist.bed")
    library(BSgenome.Hsapiens.UCSC.hg19)
    bedUtils(bedInput = bedfile,maxFragLen = 100, chrFilterList = NULL) %>%
    atacPeakCalling %>% atacPeakQC(qcbedInput = blacklistfile, bsgenome = BSgenome.Hsapiens.UCSC.hg19)
    dir(td)

[Package esATAC version 1.4.5 Index]