counts2fpkm | R Documentation |
Takes a count matrix and a vector of gene lengths and returns an optionally log2
-transformed FPKM matrix. Modified from edgeR.
counts2fpkm(x, length, log = FALSE, prior.count = 0.25)
x |
a matrix of counts. |
length |
a vector of length |
log |
logical, if |
prior.count |
average count to be added to each observation to avoid
taking log of zero. Used only if |
A matrix of FPKM values.
set.seed(123)
genecounts <- matrix(sample(c(rep(0, 50), 1:100), 30), nrow=10)
lengths <- sample(1000:10000, 10)
counts2fpkm(genecounts, lengths)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.