DESeq2_tidiers | R Documentation |
This reshapes a DESeq2 transform object (output from rlog()
and
varianceStabilizingTransform()
functions) into a tidy format.
## S3 method for class 'DESeqTransform' tidy(x, colData = FALSE, ...)
x |
DESeqTransform object |
colData |
whether colData should be included in the tidied output for those in the DESeqTransform object. |
... |
extra arguments (not used) |
colDat=TRUE
adds covariates from colData to the data frame.
the result is a data frame with the columns
gene |
gene ID |
sample |
sample ID |
log2Count |
transformed normalized counts in this gene in this sample on a log2 scale |
If colData = TRUE
, it also merges this with the columns present
in colData(x)
.
Unclear what the license for this code might be. It's copied directly from https://gist.github.com/tavareshugo/3973461a7daf8a43e65e3566d5deed14
Hugo Tavares https://gist.github.com/tavareshugo/3973461a7daf8a43e65e3566d5deed14
# From DESeq2 documentation if (require("DESeq2")) { dds = makeExampleDESeqDataSet(betaSD = 1) # vst transform vst_norm = varianceStabilizingTransformation(dds) # rlog transform rlog_norm = rlog(dds) tidy(rlog_norm) tidy(vst_norm) # With design included tidy(rlog_norm, colData=TRUE) tidy(vst_norm, colData=TRUE) }
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.