Calculate the sparsity (as a count or proportion) of a gene expression count matrix.
Arguments
- seu_obj
A Seurat object.
- features
An optional vector of feature names (e.g., gene symbols) to include in the calculation. Defaults to NULL, in which case the calculation uses all available features in the RNA assay of the Seurat object.
- expMat
Path to exprMatrix file.
- platform
The platform from which the data originates. Valid options are 'Xenium', 'CosMx', and 'Merscope'.