scatterVDJ | R Documentation |
scatterVDJ
creates a scatterplot that shows the
abundance of the sample on the x-axis and the evenness on the y-axis.
scatterVDJ(d, ...)
## S4 method for signature 'matrix'
scatterVDJ(d, sampleGroups = NULL, title = NULL, legend = FALSE)
d |
A |
... |
additional arguments. |
sampleGroups |
A |
title |
Character vector with an optional title. |
legend |
If TRUE, a legend will be included with the plot. If FALSE, no legend is included in the plot. |
Returns a ggplot
plot with a scatterplot that shows the
abundance for each sample on the x-axis and the evenness for each sample
on the y-axis. Richness can be expressed as the total number of unique
clonotypes in the sample or as the breakaway diversity measure (Willis and
Bunge 2015), which estimates the total number of unique clonotypes in the
population. Evenness is measured as the normalized entropy, which
is a measure of how evenly cells are distributed across the different
clonotypes. Evenness is a measure between 0 and 1 that is independent of
the number of cells in a sample.
Diversity measures such as Shannon entropy contain information about
both the evenness and the abundance of a sample, but because both
characteristics are combined into one number, comparison between
samples or groups of samples is difficult. Other measures, such as the
breakaway measure of diversity, only express the abundance of the sample
and not the evenness. The scatterplot shows how evenness and abundance
differs between each sample and between each group of samples.
data('contigs')
x <- clonoStats(contigs)
d <- calculateDiversity(x)
sampleGroups <- data.frame(Sample = c("sample1", "sample2"),
Group = c("Cancer", "Normal"))
scatterVDJ(d, sampleGroups = NULL,
title = "Evenness-abundance plot", legend = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.