\HeaderA{specPeaks}{Identify peaks in a sparse continuum mode spectrum}{specPeaks}
\keyword{manip}{specPeaks}
\begin{Description}\relax
Given a spectrum, identify and list significant peaks as determined
by several criteria.
\end{Description}
\begin{Usage}
\begin{verbatim}
specPeaks(spec, sn = 20, mzgap = 0.2)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{spec}] matrix with named columns \code{mz} and \code{intensity}
\item[\code{sn}] minimum signal to noise ratio
\item[\code{mzgap}] minimal distance between adjacent peaks, with smaller peaks
being excluded

\end{ldescription}
\end{Arguments}
\begin{Details}\relax
Peaks must meet two criteria to be considered peaks: 1) Their
s/n ratio must exceed a certain threshold. 2) They must not be
within a given distance of any greater intensity peaks.
\end{Details}
\begin{Value}
A matrix with columns:

\begin{ldescription}
\item[\code{mz}] m/z at maximum peak intensity
\item[\code{intensity}] maximum intensity of the peak
\item[\code{fwhm}] full width at half max of the peak
\end{ldescription}
\end{Value}
\begin{Author}\relax
Colin A. Smith, \email{csmith@scripps.edu}
\end{Author}
\begin{SeeAlso}\relax
\code{\LinkA{getSpec}{getSpec}},
\code{\LinkA{specNoise}{specNoise}}
\end{SeeAlso}

