commonSeqsBar: Common sequences bar plot

View source: R/commonSeqsBar.R

commonSeqsBarR Documentation

Common sequences bar plot

Description

Creates an UpSetR bar plot showing the number of intersecting sequences across multiple repertoire_ids. This function is useful when more than 3 repertoire_ids are being compared.

Usage

commonSeqsBar(
  productive_aa,
  repertoire_ids,
  color_sample = NULL,
  color_intersection = NULL,
  color = "#377eb8",
  labels = "no"
)

Arguments

productive_aa

A tibble of productive amino acid sequences generated by LymphoSeq function productiveSeq where the aggregate parameter was set to "junction_aa".

repertoire_ids

The names of two or more repertoire_ids in the productive_aa list whose intersections will shown.

color_sample

The name of a single repertoire_id in the productive_aa list whose sequences will be colored in all repertoire_ids that they appear in.

color_intersection

The names of two or more repertoire_ids in the productive_aa list whose intersections will be colored.

color

A character vector of a color name that will be used highlight a selected repertoire_id or multiple repertoire_id intersections.

labels

A character vector indicating whether the number of intersecting sequences should be shown on the tops of the bars. Options include "yes" or "no".

Value

Returns an UpSetR bar plot showing the number of intersecting sequences across multiple repertoire_ids.

See Also

commonSeqs

Examples

file_path <- system.file("extdata", "TCRB_sequencing", package = "LymphoSeq2")

stable <- readImmunoSeq(path = file_path)

atable <- productiveSeq(stable, aggregate = "junction_aa")

commonSeqsBar(atable, repertoire_ids = c("TRB_CD4_949", "TRB_CD8_949",
"TRB_Unsorted_949", "TRB_Unsorted_1320"), color_sample = "TRB_CD8_949")

elulu3/LymphoSeqTest documentation built on Aug. 27, 2022, 5:47 a.m.