multi_norm: Normalise nanostring mRNA data using multiple algorithms

Description Usage Arguments Value References Examples

View source: R/multi_norm.R

Description

Performs nCounter scaling factor based normalisations using spike-in controls and housekeeping genes and uses wrappers for geNorm, variance stabilising normalisation (vsn), cyclic loess, quantile and RUV-III normalisation.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
multi_norm(
  count_set = NULL,
  norm_method = "all",
  background_correct = "proportional",
  positive_control_scaling = TRUE,
  count_threshold = 0,
  geNorm_n = 5,
  plot_dir = NULL,
  ruv_k = 1
)

Arguments

count_set

A count_set of mRNA counts generated using count_set

norm_method

types of normalizations to perform. DEFAULT = "all", other = c("housekeeping_scaled", "all_endogenous_scaled", "geNorm_housekeeping", "loess", "vsn", "quantile", ruvIII")

background_correct

Background correction by calculating the proportion of each sample that are background counts, based on spike in negative controls. DEFAULT = "proportional", other = "mean2sd", "none"

positive_control_scaling

Option to perform scaling factor normalisation to the geometric mean of the positive controls. TRUE/FALSE Default = TRUE

count_threshold

Threshold above which at which a gene is considered to be expressed. Any integer. Default = 0. Options are "mean2sd" or any number. To apply no threshold, use -1.

geNorm_n

number of housekeeping genes to keep after ranking using the geNorm algorithm. Default = 5.

plot_dir

Where to write the files to? The directory must already exist. e.g. "/full/path/to/my/plots/". Default = NULL. No plot will be saved if NULL

ruv_k

k value for RUVIII normalisation. Default = 1. See RUV package for more details.

Value

Returns a count_set containing log2 transformed, normalised data and a diagnostic plot report

References

Wolfgang Huber, Anja von Heydebreck, Holger Sueltmann, Annemarie Poustka and Martin Vingron. Variance Stabilization Applied to Microarray Data Calibration and to the Quantification of Differential Expression. Bioinformatics 18, S96-S104 (2002).

Gautier, L., Cope, L., Bolstad, B. M., and Irizarry, R. A. 2004. affy—analysis of Affymetrix GeneChip data at the probe level. Bioinformatics 20, 3 (Feb. 2004), 307-315.

Ben Bolstad (2018). preprocessCore: A collection of pre-processing functions. R package version 1.44.0. https://github.com/bmbolstad/preprocessCore

Johann Gagnon-Bartsch (2018). ruv: Detect and Remove Unwanted Variation using Negative Controls. R package version 0.9.7. https://CRAN.R-project.org/package=ruv

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
# biological groups
rnf5_group <- c(rep("WT", 5), rep("KO", 5))

# sample ids
rnf5_sampleid <- c("GSM3638131", "GSM3638132", "GSM3638133", "GSM3638134",
                  "GSM3638135", "GSM3638136", "GSM3638137", "GSM3638138",
                  "GSM3638139", "GSM3638140")

# build count_set
rnf5_count_set <- count_set(count_data = Rnf5,
                            group = rnf5_group,
                            samp_id = rnf5_sampleid)
# normalize
rnf5_count_set_norm <- multi_norm(count_set = rnf5_count_set,
                       positive_control_scaling = TRUE,
                       background_correct = "mean2sd",
                       #plot_dir = "~/Dropbox/git/NanoStringClustR/plot_test/"
                       )

MarthaCooper/NanoStringClustR documentation built on June 25, 2021, 9:41 p.m.