Skip to contents

Write pseudobulk peaks in narrowPeak format

Usage

write_pseudobulk_peaks(
  pb,
  dir,
  scope = c("both", "group", "union"),
  verbose = getOption("MarchR.verbose", FALSE)
)

Arguments

pb

(MarchRPseudobulk) Output of pseudobulk_fragments().

dir

(character) Output directory. Files land in <dir>/peaks/.

scope

(character) Which peak sets to write. One of "both", "group", "union". Default "both".

verbose

(logical) Print progress messages. Default getOption("MarchR.verbose", FALSE).

Value

pb with a peaks_path column added to its manifest.

Details

Column 10 of narrowPeak is the summit offset from start. It is taken from the stored summit_pos rather than assumed to be half the peak width, because peaks clamped at a chromosome start are not centered on their summit.