run.baselines {FTICRMS} | R Documentation |
Takes the spectra from files in raw.dir
, calculates and subtracts the baselines from them,
and writes the results in the directory base.dir
.
run.baselines(root.dir = ".", raw.dir, base.dir, overwrite = FALSE, use.par.file = FALSE, par.file = "parameters.RData", sm.par = 1.1E-9, neg.pen = sqrt(pi/2), k.biweight = 6, max.iter = 30, frac.changed = 0.001)
root.dir |
string containing location of raw data directory |
raw.dir |
directory for raw data files; default is paste(root.dir, "/Raw_Data", sep = "") |
base.dir |
directory for baseline-corrected files; default is paste(root.dir, "/Baseline_Corrected", sep = "") |
overwrite |
logical; whether to replace existing files with new ones |
use.par.file |
logical; if TRUE , then parameters are read from
par.file in directory root.dir |
par.file |
string containing name of parameters file |
sm.par |
smoothing parameter for baseline calculation |
neg.pen |
negativity penalty in baseline calculation |
k.biweight |
parameter for robust center and scale estimation using Tukey's biweight |
max.iter |
convergence criterion in baseline calculation |
frac.changed |
convergence criterion in baseline calculation |
Goes through the entire directory raw.dir
file-by-file and computes each baseline using baseline
,
subtracts the baseline from the spectrum, and writes the resulting data frame to a file in directory base.dir
.
The name of the new file is the same as the name of the old file with “.txt” replaced by “.RData”, and the
new file is ready to be used by run.peaks
.
No value returned; the files are simply created.
If use.par.file = TRUE
, then the parameters read in from the file overwrite any arguments entered in the
function call.
Don Barkauskas (barkda@wald.ucdavis.edu)
Barkauskas, D.A. et al. (2008) “Detecting glycan cancer biomarkers in serum samples using MALDI FT-ICR mass spectrometry data”. Submitted to Bioinformatics
Xi, Y. and Rocke, D.M. (2008) “Baseline Correction for NMR Spectroscopic Metabolomics Data Analysis”. BMC Bioinformatics, 9:324.