generateSAF: Generate a peak annotation file

View source: R/scAPAtrap_funlib.R

generateSAFR Documentation

Generate a peak annotation file

Description

Generate a peak annotation file (PeakID/chr/start/end/Strand) by combining forward peaks and reverse peaks generated by findPeaks

Usage

generateSAF(forwardPeaks, reversePeaks, outputdir, ...)

Arguments

forwardPeaks

A peak filename or a peak data.frame of forward strand, which is the output of findPeaksByStrand or findPeaks, where strand = +.

reversePeaks

Save as forwardPeaks but on the reverse strand. Can provide forwardPeaks or reversePeaks, or both.

outputdir

Output file directory.

...

Arguments passed to other methods and/or advanced arguments. Advanced arguments:

verbose

If 'TRUE' basic status updates will be printed along the way.

logf

If not NULL, then it should be a character string denoting a file name. Then message will be written to 'logf'.

Value

Full path of the peak list (<outputdir>/peaks.saf). This file contains five columns without header: peakID/chr/start/end/strand.

Examples

## Not run: 
forwardPeaks <-findPeaks(fullcovF,'+', 98, 1000, cutoff = 1)
reversePeaks <-findPeaks(fullcovR,'-',98, 1000, cutoff = 1)
generateSAF(forwardPeaks, reversePeaks,'./data')

## End(Not run)

BMILAB/scAPAtrap documentation built on Oct. 13, 2023, 2:36 a.m.