TACS: Make a FACS-like plot from a single-cell rna-seq dataset.

Description Usage Arguments

Description

Make a FACS-like plot from a single-cell rna-seq dataset.

Usage

1
2
3
4
5
6
7
8
TACS(dge, gene1, gene2, cutoffs = NULL, return_val = "plot", density = F,
  facet_by = NULL, include_panel_with_all = FALSE,
  facet_levels = FetchData(dge, facet_by)[[1]] %>% factor %>% levels %>%
  c(rep("all", include_panel_with_all), .),
  col = stats::setNames((scales::hue_pal())(length(facet_levels) -
  include_panel_with_all), facet_levels[(include_panel_with_all +
  1):length(facet_levels)]), num_genes_add = 100,
  genesets_predetermined = F, dge_reference = dge, ...)

Arguments

dge

Seurat object

gene1

Horizontal axis on plot mimics this gene. Character, usually length 1 but possibly longer.

gene2

Vertical axis on plot mimics this gene. Character, usually length 1 but possibly longer.

cutoffs

If given, divide plot into four quadrants and annotate with percentages. Numeric vector of length 2.

return_val

If "all", returns a list with several internal calculations revealed. If "plot", returns just a ggplot object. If "seurat", returns a Seurat object with gene scores added.

density

If TRUE, plot contours instead of points.

num_genes_add

Each axis shows a simple sum of similar genes. This is how many (before removing overlap). Integer.

genesets_predetermined

If FALSE, plot the sum of many genes similar to gene1 instead of gene1 alone (same for gene2). See ?get_similar_genes. If TRUE, plot the sum of only the genes given.

dge_reference

Seurat object. This function relies on gene-gene correlation. If your dataset is perturbed in a way that would substantially alter gene-gene correlations, for example if different time points are present or certain cell types are mostly depleted, you can feed in a reference dge, and TACS will choose axes based on the reference data.

...

Extra params for stat_density2d.

This function is based on a simple scheme: choose genes similar to the ones specified and average them to reduce the noise.


maehrlab/thymusatlastools documentation built on May 28, 2019, 2:32 a.m.