abundanceContig: Demonstrate the relative abundance of clonotypes by group or...

Description Usage Arguments Value Examples

View source: R/viz.R

Description

This function takes the output of combineTCR(), combineBCR(), or expression2List() and displays the number of clonotypes at specific frequencies by sample or group. Visualization can either be a line graph using calculated numbers or if scale = TRUE, the output will be a density plot. Multiple sequencing runs can be group together using the group parameter. If a matrix output for the data is preferred, set exportTable = TRUE.

Usage

1
2
3
4
5
6
7
abundanceContig(
  df,
  cloneCall = "gene+nt",
  scale = FALSE,
  group = NULL,
  exportTable = FALSE
)

Arguments

df

The product of combineTCR(), combineBCR(), or expression2List().

cloneCall

How to call the clonotype - CDR3 gene (gene), CDR3 nucleotide (nt), CDR3 amino acid (aa), or C DR3 gene+nucleotide (gene+nt).

scale

Converts the graphs into denisty plots in order to show relative distributions.

group

The column header for which you would like to analyze the data.

exportTable

Exports a table of the data into the global environment in addition to the visualization.

Value

ggplot of the total or relative adundance of clonotypes across quanta

Examples

1
2
3
4
5
#Making combined contig data
x <- contig_list
combined <- combineTCR(x, rep(c("PX", "PY", "PZ"), each=2), 
rep(c("P", "T"), 3), cells ="T-AB")
abundanceContig(combined, cloneCall = "gene", scale = FALSE)

scRepertoire documentation built on Nov. 8, 2020, 7 p.m.