Signac (version 0.2.4)

CutMatrix: Generate matrix of integration sites

Description

Generates a cell-by-position matrix of Tn5 integration sites centered on a given region (usually a DNA sequence motif). This matrix can be used for downstream footprinting analysis.

Usage

CutMatrix(
  object,
  region,
  tabix.file = NULL,
  assay = NULL,
  cells = NULL,
  verbose = TRUE
)

Arguments

object

A Seurat object

region

A GRanges object containing the region of interest

tabix.file

A TabixFile object. If NULL, the file specified in fragment.path will be opened and closed after the function completes. If iterating over many regions, providing an open TabixFile is much faster as it avoids opening and closing the connection each time.

assay

Name of the assay to use

cells

Which cells to include in the matrix. If NULL (default), use all cells in the object

verbose

Display messages

Value

Returns a sparse matrix

Examples

Run this code
# NOT RUN {
fpath <- system.file("extdata", "fragments.tsv.gz", package="Signac")
atac_small <- SetFragments(atac_small, file = fpath)
CutMatrix(
 object = atac_small,
 region = StringToGRanges("chr1-10245-762629")
)
# }

Run the code above in your browser using DataLab