Plot multiple for a given peak in peak table. Wrapper for
plot_spectrum
.
plot_all_spectra(
peak,
peak_table,
chrom_list,
chrs = "all",
plot_spectrum = TRUE,
export_spectrum = TRUE,
scale_spectrum = TRUE,
overlapping = TRUE,
verbose = FALSE,
...
)
If export_spectrum
is TRUE, returns the spectra as a
data.frame
with wavelengths as rows and one column for each sample in the
chrom_list
encoding the absorbance (or normalized absorbance, if
scale_spectrum
is TRUE) at each wavelength. Otherwise, there is no
return value.
The name of a peak to plot (in character format)
The peak table (output from get_peaktable
function)
A list of profile matrices, each of the same dimensions (timepoints x components).
Vector of chromatograms to plot.
Logical. If TRUE, plots the spectrum of the chosen peak.
Logical. If TRUE, exports spectrum to console. Defaults to FALSE.
Logical. If TRUE, scales spectrum to unit height.
Logical. If TRUE, plot spectra in single plot.
Logical. If TRUE, prints verbose output to console.
Additional arguments to plot_spectrum.
If plot_spectrum
is TRUE, plots the spectra for the specified chromatogram
(chr
) of the given peak
. The spectrum is a single row
from the chromatographic matrix.
Ethan Bass
plot_spectrum
if (FALSE) { # interactive()
data(Sa_warp)
pks <- get_peaks(Sa_warp, lambda="220")
pk_tab <- get_peaktable(pks)
plot_all_spectra(peak="V13", peak_table = pk_tab, overlapping=TRUE)
}
Run the code above in your browser using DataLab