Skip to contents

Analyzes matrix data by UMAP and saves results to reducedDims slot of TapestriObject.

Usage

runUMAP(
  TapestriExperiment,
  alt.exp = "alleleFrequency",
  assay = NULL,
  use.pca.dims = TRUE,
  pca.dims = NULL,
  ...
)

Arguments

TapestriExperiment

TapestriExperiment object

alt.exp

Character, altExp to use, NULL uses top-level/main experiment. Default "alleleFrequency".

assay

Character, assay to use. NULL (default) uses first-indexed assay. Not used when use.pca.dims = TRUE.

use.pca.dims

Logical, if TRUE, uses experiment PCA, otherwise uses assay data. Default TRUE.

pca.dims

Numeric, indices of PCs to use in UMAP. Default NULL.

...

Additional parameters to pass to umap::umap(), e.g. for configuration (see umap::umap.defaults()).

Value

TapestriExperiment with UMAP embeddings saved to reducedDims slot of altExp.

Examples

tap.object <- newTapestriExperimentExample() # example TapestriExperiment object
#>  Moving gRNA probe  to `altExp` slot "grnaCounts".
#>  Moving barcode probe  to `altExp` slot "barcodeCounts".
#>  Moving chrY probe(s) probe_231, probe_232, probe_233, probe_234, probe_235, probe_236, probe_237, probe_238, probe_239, and probe_240 to `altExp` slot "chrYCounts".
tap.object <- runPCA(tap.object, alt.exp = "alleleFrequency")
tap.object <- runUMAP(tap.object, pca.dims = 1:3)
#>  Running UMAP on: alleleFrequency.