Description Usage Arguments Value Examples
View source: R/batch_correction.R
Normalize bathces by either reference samples of population median. Uses normalizeBatches function from the batchCorr package
1 | normalize_batches(object, batch, group, ref_label, ...)
|
object |
a MetaboSet object |
batch, group |
character, column names of pData with batch labels and group labels |
ref_label |
the label of the reference group i.e. the group that is constant through batches |
... |
additional parameters passed to batchCorr::normalizeBatches |
list, the object with normalized features and information on which features were corrected by ref samples in each batch.
1 2 3 4 5 | # Batch correction
batch_corrected <- normalize_batches(merged_sample, batch = "Batch", group = "QC", ref_label = "QC")
# Evaluate batch correction
pca_bhattacharyya_dist(merged_sample, batch = "Batch")
pca_bhattacharyya_dist(batch_corrected, batch = "Batch")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.