normMethod_median.Rd
Called internally by normSpectra()
. Evaluates the median of each spectrum in a dataset after removing 0 values introduced by mapping. If the medians are not equal between spectra, a normalization factor is applied to the spectral intensities until all median intensities in the dataset are equal. Capable of normalizing 2-6 spectra at once.
norm_median(dat, mass_dat, spectra_cols)
dat | The name of the spectral data frame, containing |
---|---|
mass_dat | A character string; the name of the column in |
spectra_cols | A character string; the names of the column in |
Returns a new data frame including the original m/z data and normalized intensity data.
https://github.com/wesleyburr/subMaldi
Kristen Yeh <kristenyeh@trentu.ca> Wesley Burr <wesleyburr@trentu.ca>
## Load sample dataset "Master2.rda" data("Master2") ## Normalize spectra "Before1" and "Before2" to their median intensity ex <- normSpectra(dat = Master, mass_dat = "full_mz", method = "median", spectra_cols = c("Before1", "Before2"))