View source: R/quantification.R
FeatureMatrix | R Documentation |
Construct a feature x cell matrix from a genomic fragments file
FeatureMatrix(
fragments,
features,
keep_all_features = FALSE,
cells = NULL,
process_n = 2000,
sep = c("-", "-"),
verbose = TRUE
)
fragments |
A list of |
features |
A GRanges object containing a set of genomic intervals. These will form the rows of the matrix, with each entry recording the number of unique reads falling in the genomic region for each cell. |
keep_all_features |
By default, if a genomic region provided is on a chromosome that is not present in the fragment file, it will not be included in the returned matrix. Set 'keep_all_features' to TRUE to force output to include all features in the input ranges. Note that features on chromosomes that are not present in the fragment file will be filled with zero counts. |
cells |
Vector of cells to include. If NULL, include all cells found in the fragments file |
process_n |
Number of regions to load into memory at a time, per thread. Processing more regions at once can be faster but uses more memory. |
sep |
Vector of separators to use for genomic string. First element is used to separate chromosome and coordinates, second separator is used to separate start and end coordinates. |
verbose |
Display messages |
Returns a sparse matrix
fpath <- system.file("extdata", "fragments.tsv.gz", package="Signac")
fragments <- CreateFragmentObject(fpath)
FeatureMatrix(
fragments = fragments,
features = granges(atac_small)
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.