Skip to contents

Coerce all matrices in datasets to use the same cells

Usage

# S3 method for class 'MarchRDataset'
align_cells(proj, how = c("intersect", "zero_fill"))

# S3 method for class 'MarchRProject'
align_cells(proj, datasets = NULL, how = c("intersect", "zero_fill"))

Arguments

proj

(MarchRDataset or MarchRProject) The project or dataset to align cells in.

how

(character) Method to align cells. One of intersect or zero_fill. intersect will keep only cells that are present in all matrices and fragments. zero_fill will fill in missing cells with zeros. Missing metadata entries are filled with NA. Fragment objects retain only observed fragments, with empty cells included in their cell-name index.

datasets

(character vector) A vector of dataset names to align.

...

Additional arguments for future extensibility.

Value

(proj) The project or dataset with aligned cells.

See also

validate_cell_alignment() zero_fill_matrix()