For each column selected, this template will produce a plot (UMAP/TSNE/PCA; your choice) using the data in that column to color the cells

plotMetadata(
  object,
  samples.to.include,
  metadata.to.plot,
  columns.to.summarize,
  summarization.cut.off = 5,
  reduction.type = "tsne",
  use.cite.seq = FALSE,
  show.labels = FALSE,
  legend.text.size = 1,
  legend.position = "right",
  dot.size = 0.01
)

Arguments

object

A combined Seurat Object with metadata to plot

samples.to.include

Which samples you would like to include

metadata.to.plot

The metadata columns from your Metadata table you would like to plot

columns.to.summarize

The columns you would like to summarize

summarization.cut.off

Select the number of categories you want to display, while marking all other cells as "other." Default is 5

reduction.type

What kind of visualization you would like to use to plot your cells and metadata (tsne, umap, pca). Default is tsne

use.cite.seq

TRUE if you would like to plot Antibody clusters from CITEseq instead of scRNA. Default is FALSE

show.labels

Whether to add labels or not to your reduction map. Default is FALSE

legend.text.size

Customize the size of the legend text in your charts. Default is 1

legend.position

Select how you want to align your legend. Default is "right"

dot.size

The size of the dots displayed on the plot. Default os 0.01

Value

a data.frame extracted from the Seurat object and plot

Details

This is a downstream template for the Single-cell RNA-seq workflow (requires dataset where Filter/QC/SingleR annotations have been run first)