Skip to contents

Metabodecon1D Usage Example

The MetaboDecon1D package is the predecessor of this package and can be downloaded from uni-regensburg.de/medicine/functional-genomics/staff/prof-wolfram-gronwald/software. We include this usage example in here so we can easily reference old behaviour and point out added features in metabodecon.

Install the package

  1. Open the following link in your browser: uni-regensburg.de/medicine/functional-genomics/staff/prof-wolfram-gronwald/software
  2. Click MetaboDecon1D: An R-package for the Deconvolution and Integration of 1D NMR data
  3. Download MetaboDecon1D_0.2.2.tar.gz
  4. Start an R session and enter command install.packages("C:/Users/tobi/Downloads/MetaboDecon1D_0.2.2.tar.gz", repos = NULL, type = "source") (replace C:/Users/tobi/Downloads/MetaboDecon1D_0.2.2.tar.gz with the path to the downloaded file on your computer)

Load package

library(MetaboDecon1D)

Deconvolute one spectrum in Bruker format

result <- MetaboDecon1D(
    filepath = "load_example_path",
    filename = "example_human_urine_spectrum",
    file_format = "bruker"
)

Visualize results and store plots as png

Deconvolute one spectrum in jcamp-dx format

result <- MetaboDecon1D(
    filepath = "load_example_path",
    filename = "example_human_urine_spectrum.dx",
    file_format = "jcampdx"
)
str(result)

Deconvolute multiple spectra in Bruker format

result <- MetaboDecon1D(
    filepath = "load_example_path",
    file_format = "bruker"
)
str(result)

Deconvolute multiple spectra in jcamp-dx format

jcamp_results <- MetaboDecon1D(
    filepath = "load_example_path",
    file_format = "jcampdx"
)
plot_triplets(jcamp_results)
plot_lorentz_curves_save_as_png(jcamp_results)
plot_spectrum_superposition_save_as_png(jcamp_results)