Skip to contents

Emits a 10x-style chr/start/end/barcode TSV per group, the format sequence-to-signal models consume as their reads input.

Usage

write_pseudobulk_fragments(
  pb,
  dir,
  append_5th_column = FALSE,
  verbose = getOption("MarchR.verbose", FALSE)
)

Arguments

pb

(MarchRPseudobulk) Output of pseudobulk_fragments().

dir

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

append_5th_column

(logical) Write a 5th column. BPCells fills it with a literal 0, not a duplicate count. Default FALSE.

verbose

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

Value

pb with a fragments_path column added to its manifest.

Details

Fragment coordinates are written in their native convention. Tn5 shift correction is deliberately not applied here: downstream model tooling generally detects and normalizes the input's existing shift itself, and pre-shifting would put two independent corrections on the same coordinate.