Plot spectrum approx for variable range
plot_spectrum_superposition_save_as_png.Rd
The MetaboDecon1D package also comprise the additional function plot_spectrum_superposition_save_as_png() to plot the original spectrum and the superposition of all generated Lorentz curves and save the result as png under the filepath.
Arguments
- deconv_result
Saved result of the MetaboDecon1D() function
- x_range
Row vector with two entries consisting of the ppm start and the ppm end value to scale the range of the x-axis (optional)
- y_range
Row vector with two entries consisting of the ppm start and the ppm end value to scale the range of the y-axis (optional)
Examples
if (FALSE) {
# Load one spectrum (Bruker format)
result <- MetaboDecon1D(
filepath="load_example_path",
filename="urine",
file_format="bruker"
)
plot_spectrum_superposition_save_as_png(result)
# Load more spectra (Bruker format)
result <- MetaboDecon1D(filepath="load_example_path", file_format="bruker")
# Plot superposition of Lorentz curves of all spectra
plot_spectrum_superposition_save_as_png(result)
# Plot superposition of Lorentz curves of one certain investigated spectrum
plot_spectrum_superposition_save_as_png(result$urine)
}