Skip to contents

Combines two or more per-modality dimensionality-reduction embeddings (e.g. ATAC LSI and RNA LSI) into a single joint embedding for multi-omic analysis.

Usage

add_combined_dims(x, ...)

# S3 method for class 'MarchRProject'
add_combined_dims(
  x,
  embedding_names,
  output_name = "CombinedDims",
  dim_weights = NULL,
  dataset_names = character(0),
  overwrite = FALSE,
  ...
)

Arguments

x

(MarchRProject) Project holding the per-modality embedding assays.

...

Passed to methods.

embedding_names

(character) Two or more existing embedding assay names to combine.

output_name

(character) Name of the stored combined embedding assay. Default "CombinedDims".

dim_weights

(numeric; optional) Per-modality weight, one per embedding. Default equal weights.

dataset_names

(character) Datasets to operate on. Default all datasets.

overwrite

(logical) Overwrite an existing assay named output_name. Default FALSE.

Value

The MarchRProject with the combined embedding stored as an assay named output_name in each selected dataset.

Details

Each modality is variance-normalized by 1 / sqrt(sum of per-dimension variances), where the variances are computed globally across the selected datasets, then scaled by its weight and concatenated. The result is stored as an assay only (no DimReduction object), so it must be passed explicitly as embedding_name to add_umap or add_clusters.

ArchR correspondence

Analogous to ArchR's addCombinedDims(). MarchR omits ArchR's per-modality dimsToUse, scaleDims, and corCutOff because those are applied at fit time by IterativeLSI.