relAbFromCounts: Relative Abundance from Counts

Description Usage Arguments Details Value Examples

View source: R/proportions.R

Description

Gets relative abundance of each channel from counts taken at several retention times

Usage

1
2
relAbFromCounts(Count, Channel, RT, data, TimePoint, method = c("lm", "rlm",
  "lqs", "rq", "sum", "log"), norm_channel, threshold, cutoff, nboot = 0)

Arguments

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

Details

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.

Value

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

Examples

1

HegemanLab/ProteinTurnover documentation built on May 6, 2019, 11:50 p.m.