qMS: Draw a Simple Mass Spectrum Showing the Parent Ion

Description Usage Arguments Details Value Author(s) Examples

View source: R/qMS.R

Description

Given a molecular formula, this function computes the mass of the parent ion, including any M + n peaks due to Br or Cl, and plots it. Intended to draw the parent ion region for small organic molecules, especially those with Br or Cl.

Usage

1
2
qMS(f = NULL, xlab = "m/z", ylab = "intensity", main = "Mass Spectrum",
  ...)

Arguments

f

A character string giving the molecular formula of the molecule of interest. Order of elements does not matter. Elements should be given as their atomic symbols, e.g. "Br" not "br".

xlab

A character string giving the x axis label.

ylab

A character string giving the y axis label.

main

A character string giving the title of the plot.

...

Additional arguments to be passed downstream.

Details

The function currently accepts formulas containing C, H, N, O, Br and Cl in any quantities.

Value

Draws a plot. Returns a data frame giving the peak masses and relative intensites.

Author(s)

Bryan A. Hanson, DePauw University. hanson@depauw.edu

Examples

1
ms <- qMS(f = "C5H8BrCl", xlim = c(150, 200), main = "Parent Ion of C5H8BrCl")

SpecHelpers documentation built on May 2, 2019, 11:01 a.m.