Description Usage Arguments Details Value Author(s) See Also Examples
View source: R/effectiveLibSizes.R
Extract effective (normalized) library sizes.
1 2 | ## Default S3 method:
effectiveLibSizes(y, log = FALSE, ...)
|
y |
a object of class |
log |
logical, if |
... |
other arguments are not currently used. |
This function extracts normalized library sizes, equal to the original library sizes multiplied by the corresponding normalization factors, from an edgeR data object or fitted model object.
If the object contains a row-specific offsets (i.e., a non-sparse matrix of offsets), then the offsets for the first row are returned.
A numeric matrix of effective (normalized) library sizes.
If log=TRUE
, then natural log values are returned, equal to library size offsets for a NB log-linear model.
Gordon Smyth
1 2 3 4 5 | ngenes <- 100
nsamples <- 4
y <- DGEList(counts=matrix(rnbinom(ngenes*nsamples,size=1,mu=10),ngenes,nsamples))
y <- calcNormFactors(y)
data.frame(y$samples, eff.lib.size=effectiveLibSizes(y))
|
Loading required package: limma
group lib.size norm.factors eff.lib.size
Sample1 1 806 0.9788973 788.9912
Sample2 1 1037 1.0780343 1117.9215
Sample3 1 1073 0.9279603 995.7014
Sample4 1 1012 1.0211767 1033.4309
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.