rla
calculates the relative log abundances (RLA, see reference) on a
numeric
vector.
Arguments
- x
numeric
(forrla
) ormatrix
(forrowRla
) with the abundances (in natural scale) on which the RLA should be calculated.- group
factor
,numeric
orcharacter
with the same length thanx
that groups values inx
. If omitted all values are considered to be from the same group.- log.transform
logical(1)
whetherx
should be log2 transformed. Set tolog.transform = FALSE
ifx
is already in log scale.
Value
numeric
of the same length than x
(for rla
) or matrix
with
the same dimensions than x
(for rowRla
).
Details
The RLA is defines as the (log) abundance of an analyte relative to the median across all abundances of the same group.
References
De Livera AM, Dias DA, De Souza D, Rupasinghe T, Pyke J, Tull D, Roessner U, McConville M, Speed TP. Normalizing and integrating metabolomics data. Anal Chem 2012 Dec 18;84(24):10768-76. doi: 10.1021/ac302748b