Plot fits for series of spectra with parameters from a peak data frame

plot_peak_df(
  peak_df,
  spectra,
  noise_sigma = NULL,
  noise_cutoff = 4,
  omega0_plus = c(0.075, 0.75) * 2,
  cex = 0.2,
  lwd = 0.25,
  label = TRUE,
  label_col = "black",
  p0 = NULL,
  p1 = NULL,
  add = FALSE
)

Arguments

peak_df

data frame with peak data as produced by param_list_to_peak_df.

spectra

list of spectra corresponding to the volumes found in peak_df.

noise_sigma

numeric vector of noise levels associated with each spectrum. If NULL, it is calculated with noise_estimate.

noise_cutoff

numeric value used to calculate the lowest contour level according to noise_sigma*noise_cutoff.

cex

numeric value by which to scale blue points and labels.

lwd

numeric value giving width of contour lines.

label

logical indicating whether to draw text labels and connecting lines.

p0

zero order phase for plotting modeled peaks.

p1

first order phase for plotting modeled peaks.

add

logical indicating whether to suppress generation of a new plot and add to an existing plot.

Details

The raw spectral data is shown in black contours and the modeled peak intensity is shown in red. The centers of peaks are shown with semi-transparent blue dots, with the area of the dot proportional to the volume of the peak (m0). Blue lines connect peaks from modeled doublets. Singlets or doublets are labeled with the syntax <peak>:<fit>. If an F-test p-value column is present (f_pvalue), that will be given below the peak label.