DEqual | R Documentation |
A DEqual plot compares the effect of RNA degradation from an independent
degradation experiment on the y axis to the effect of the outcome of
interest. They were orignally described by Jaffe et al, PNAS, 2017
https://doi.org/10.1073/pnas.1617384114. Other DEqual versions are
included in Collado-Torres et al, Neuron, 2019
https://doi.org/10.1016/j.neuron.2019.05.013. This function compares your
t-statistics of interest computed on transcripts against the
t-statistics from degradation time adjusting for the six brain regions from
degradation experiment data used for determining rse_tx
.
DEqual(
DE,
deg_tstats = qsvaR::degradation_tstats,
show.legend = TRUE,
show.cor = c("caption", "corner-top", "corner-bottom", "none"),
font.size = 12,
cor.size = font.size/2,
cor.label = "cor: "
)
DE |
a |
deg_tstats |
an optional |
show.legend |
logical (default TRUE) to show legend in the plot |
show.cor |
specify where to show the correlation value. Can be one of "caption", "corner-top", "corner-bottom", or "none". |
font.size |
numeric value to set the base font size of the plot |
cor.size |
numeric (default font.size/2) to set the font size for the correlation text |
cor.label |
character (default "cor: ") to set the text preceding the correlation value |
a ggplot
object of the DE t-statistic vs
the DE statistic from degradation
## Random differential expression t-statistics for the same transcripts
## we have degradation t-statistics for in `degradation_tstats`.
set.seed(101)
random_de <- data.frame(
t = rt(nrow(degradation_tstats), 5),
row.names = sample(
rownames(degradation_tstats),
nrow(degradation_tstats)
)
)
## Create the DEqual plot
DEqual(random_de)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.