McPeaks is a shallow object holding ATAC data over metacells.
Minimally it should include a count matrix of peaks over metacells, and PeakIntervals
which hold the coordinates
of the peaks.
Usage
# S4 method for McPeaks
initialize(
.Object,
mat,
peaks,
genome,
id = NULL,
description = NULL,
metadata = NULL,
cell_to_metacell = NULL,
mc_size_eps_q = 0.1,
path = "",
tad_based = TRUE,
order = NULL
)
Arguments
- mat
a numeric matrix where rows are peaks and columns are metacells. Can be a sparse matrix.
- peaks
misha intervals set. Can contain a field named 'peak_name' with a unique name per peak. Both the names and intervals should be unique (a peak cannot appear more than once).
- genome
genome assembly of the peaks. e.g. "hg38", "hg19", "mm9", "mm10"
- id
an identifier for the object, e.g. "pbmc".
- description
description of the object, e.g. "PBMC from a healthy donor - granulocytes removed through cell sorting (10k), projection was done using RNA metacells"
- metadata
data frame with a column called 'metacell' and additional metacell annotations, or the name of a delimited file which contains such annotations.
- cell_to_metacell
a data frame mapping 'cell_id' to 'metacell' (optional). See
project_atac_on_mc
- mc_size_eps_q
(optional) quantile of MC size (in UMIs) to scale the number of UMIs per metacell. \(egc_ij\) would then be the fraction of peak i in metacell j multiplied by the
mc_size_eps_q
quantile of metacell sizes.- path
path from which the object was loaded (optional)
- tad_based
whether the peak names are TAD-based
- order
a vector with the order of the metacells. If not provided, the metacells are ordered by their order in the matrix.