This function generates a scatter plot of Kendrick Mass Defect (KMD) versus
nominal mass (nm), with color-coding based on a specified variable
(z_var). Optionally, the plot can be returned as an interactive Plotly
object.
uplot_kmd(
df,
z_var = "norm_int",
palname = "redblue",
size_dots = 0.5,
col_bar = TRUE,
tf = FALSE,
logo = TRUE,
cex.axis = 12,
cex.lab = 15,
plotly = FALSE,
...
)A ggplot object (or a plotly object if plotly = TRUE)
showing KMD vs nominal mass.
A data.table or data.frame containing columns:
nm (nominal mass)
kmd (Kendrick mass defect)
the color variable given in z_var.
Character. Name of the column used for color mapping.
Character. Palette name passed to f_colorz().
Numeric. Point size.
Logical. (Reserved for future use; currently ignored.)
Logical. (Reserved for future use; currently passed to f_colorz() via ... if desired.)
Logical. If TRUE, adds a UME caption.
Numeric. Axis text size.
Numeric. Axis label size.
Logical. If TRUE, return interactive plotly object.
Arguments passed on to f_colorz
zNumeric vector. Values whose colors should be computed.
col_numInteger. Number of colors in the palette (default: 100).
verboselogical; if TRUE, show progress messages.
Kendrick Mass Defect (KMD) vs. Nominal Mass Plot
Kendrick E. (1963). A mass scale based on CH\(_2\) = 14.0000 for high resolution mass spectrometry of organic compounds. Analytical Chemistry, 35, 2146–2154.
Hughey C.A., Hendrickson C.L., Rodgers R.P., Marshall A.G., Qian K.N. (2001). Kendrick mass defect spectrum: A compact visual analysis for ultrahigh-resolution broadband mass spectra. Analytical Chemistry, 73, 4676–4681. tools:::Rd_expr_doi("10.1021/ac010560w")
Other plots:
uplot_cluster(),
uplot_cvm(),
uplot_dbe_minus_o_freq(),
uplot_dbe_vs_c(),
uplot_freq_ma(),
uplot_freq_vs_ppm(),
uplot_hc_vs_m(),
uplot_heteroatoms(),
uplot_isotope_precision(),
uplot_lcms(),
uplot_ma_vs_mz(),
uplot_ms(),
uplot_n_mf_per_sample(),
uplot_pca(),
uplot_ratios(),
uplot_reproducibility(),
uplot_ri_vs_sample(),
uplot_vk()
uplot_kmd(mf_data_demo, z_var = "norm_int", plotly = TRUE)
Run the code above in your browser using DataLab