get_meta_dt: get_meta_dt

View source: R/functions_scRNAseq.R

get_meta_dtR Documentation

get_meta_dt

Description

retrieves metadata data.table from Seurat object with reduction coordinates added. optional arguments all meta clustres to be specified by combining an existing cluster definition and factor level specification for arbitrary variables.

Usage

get_meta_dt(
  seurat_obj,
  combine_source = "seurat_clusters",
  to_combine = list(west_island = c(15, 6), west_projection = c(13, 4), lonely_island =
    c(11), north_archipelago = c(9, 8, 14, 12), main_continent = c(7, 0, 2, 16, 2, 1, 3,
    5, 10)),
  cluster_vars = c("seurat_clusters", "meta_cluster"),
  manual_factors = list(orig.ident = c("wt", "df4")),
  reduction = "umap"
)

Arguments

seurat_obj

an object of class Seurat to extract meta data from

to_combine
cluster_vars

cluster variables, will be made factors with levels ordered by decreasing size.

manual_factors

named list, names specify variables and entries specify factor levels to apply.

reduction

string to specify reduction, must be in seurat_obj@reductions


jrboyd/ssvRecipes documentation built on May 22, 2022, 7:07 a.m.