ruvms: Remove unwanted variation in mass-spectrometry data

ruvmsR Documentation

Remove unwanted variation in mass-spectrometry data

Description

The 'ruvms' function performs an 'ruv::RUVIII' like normalisation on mass-spectrometry data while allowing missing values (NAs) in input data.

Usage

ruvms(
  Y,
  M,
  ctl,
  k1 = 0,
  lambda = 1e-05,
  standardise = TRUE,
  delta = NULL,
  eta = NULL,
  include.intercept = TRUE,
  average = FALSE,
  return.info = FALSE,
  inputcheck = FALSE
)

Arguments

Y

The data. An m-by-n matrix, where m is the number of observations and n is the number of measurements.

M

The replication structure matrix. See ruv::RUVIII for details.

ctl

A logical vector of length n indicating the negative control measurements (peptides, proteins or metabolites).

k1

Tuning parameter. Default is 0.

lambda

Tuning parameter. Default is 1e-5, only needed when standardise is FALSE.

eta

Column-wise (e.g., protein-wise) covariates. See ruv::RUVI for more.

include.intercept

Logical. See ruv::RUVI for more.

average

Logical, whether to return averaged replicates after normalisation.

return.info

Logical. If FALSE, only the adjusted data matrix is returned. If TRUE, additional information is returned (see below).

input.check

Logical. A basic sanity check on the inputs.

Value

If input.check = FASLE, the normalised data matrix is returned. Otherwise a list is returned which contains

newY The normalised data matrix.
di Eigenvalues of the N matrix.
hi hi values in the generalised averging operator.
delta The delta tuning parameter.
lambda The lambda tuning parameter.

See Also

RUV1, RUVIII

Examples


# See vignettes.


Mengbo-Li/ruvms documentation built on Nov. 14, 2023, 2:11 a.m.