Description Usage Arguments Details Value Examples
Gets relative abundance of each channel from counts taken at several retention times
1 2 | relAbFromCounts(Count, Channel, RT, data, TimePoint, method = c("lm", "rlm",
"lqs", "rq", "sum", "log"), norm_channel, threshold, cutoff, nboot = 0)
|
Count |
Observed counts |
Channel |
Channels corresponding to the observed counts |
RT |
Retention times corresponding to the observed counts |
data |
An optional data frame to take the preceding variables from. |
TimePoint |
The time point that this data is from, to be optionally added to the output data frames. |
method |
Options are "lm", "rlm", "lqs", "rq", "sum", and "log". |
norm_channel |
The channel to use as baseline for the regression methods, in the output of the relative abundance, and when computing the threshold. By default, the channel with the highest total counts is used. |
threshold |
A proportion used to remove values corresponding to retention times for which the value of the norm_channel is less than this threshold times the max of the norm_channel. |
cutoff |
All counts less than or equal to this are set to missing. |
nboot |
Experimental, for bootstrapping |
The "lm", "rlm", "lqs", and "rq" methods plots the counts for each channel against the baseline channel and computes a regression; the slope is the relative abundance.
The "sum" method simply adds the counts and gets the proportion in each channel.
The "log" method takes the logs of the counts and computes a two-way ANOVA on RT and Channel; the coefficients for the channels are then converted back to relative abundances.
Plots are created using the lattice library.
A list is returned with the following elements. It is of class "regRelAb" if a regression method is used and "logRelAb" if a log model is used.
data.wide |
A table of counts, by Channel, and RT |
data.long |
The counts in long data frame format |
data |
The fitted relative abundance and proportions at each channel. |
norm_channel |
The chosen baseline channel |
coefs |
For the regression model, the fitted coefficients |
method |
The method used |
threshold |
The threshold used |
1 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.