Skip to contents

Obtain abundance values in a pmart object for QC-RLSC Normalization

Usage

bc_qcrlsc(
  omicsData,
  block_cname,
  qc_cname,
  qc_val,
  order_cname,
  missing_thresh = 0.5,
  rsd_thresh = 0.3,
  backtransform = FALSE,
  keep_qc = FALSE
)

Arguments

omicsData

an omicsData object (metabData, lipidData, pepData, or proData) created using the pmartR package, where any zero values have already been replaced with NAs and a log transformation has already been applied

block_cname

character string giving name of column in omicsData$f_Data that contains block (or batch) information

qc_cname

character string giving name of column in omicsData$f_data that contains the factor variable indicating whether sample is QC or not

qc_val

character string giving the value from the qc_cname column that indicates a QC sample

order_cname

character string giving name of column in omicsData$f_data that contains the run order

missing_thresh

numeric threshold, between 0 and 1, used for filtering out biomolecules. See details for more information. A value of 0.5 is reasonable.

rsd_thresh

numeric threshold used for filtering metabolites. See details for more information. A value of 0.3 is reasonable.

backtransform

logical value indicated whether or not to backtransform the data to put the normalized data back on the same scale as the original data. Defaults to FALSE. If TRUE, the median of the y-values of the loess curve is added to the normalized value for each biomolecule for each batch

keep_qc

logical value to determine whether or not to include QC samples in the final output of the data (default is set to FALSE)

Value

omicsData object of same class as omicsData_filt, where e_data contains the QC-RLSC normalized values

Author

Damon Leach

Examples

if (FALSE) {
library(malbacR)
library(pmartR)
data("pmart_amide")
pmart_amide <- edata_transform(pmart_amide,"log2")
pmart_amide <- group_designation(pmart_amide,main_effects = "group",batch_id = "batch")
amide_qcrlsc <- bc_qcrlsc(omicsData = pmart_amide,block_cname = "batch",
                          qc_cname = "group", qc_val = "QC", order_cname = "Injection_order",
                          missing_thresh = 0.5, rsd_thresh = 0.3, backtransform  = FALSE)
}