\HeaderA{getpspectra}{Retrieve a spectra-group peaklist}{getpspectra}
\keyword{methods}{getpspectra}
\begin{Description}\relax
Extract one group from a xsAnnotate object. Returns a peaklist with annotated peaks.
\end{Description}
\begin{Usage}
\begin{verbatim}
  getpspectra(object,grp)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{object}] xsAnnotate object
\item[\code{grp}] index of pseudo-spectra-group
\end{ldescription}
\end{Arguments}
\begin{Details}\relax
xsAnnotate groups LC/MS Peaklist after there EIC correlation and FWHM. These function extract one of these so called "pseudo spectra groups" with include the peaklist with there annotations. The annotation depends on a before called findAdducts() ( and findIsotopes() ).
Attention: The indices for the isotopes, are those from the whole peaklist. See \code{getPeaklist()}.
\end{Details}
\begin{Author}\relax
Carsten Kuhl \textless{}ckuhl@ipb-halle.de\textgreater{}
\end{Author}
\begin{Examples}
\begin{ExampleCode}
  library(CAMERA)
  file <- system.file('mzdata/MM14.mzdata', package = "CAMERA")
  xs   <- xcmsSet(c(file), method="centWave", ppm=30, peakwidth=c(5,10))
  an   <- xsAnnotate(xs)
  an   <- groupFWHM(an)
  peaklist <- getpspectra(an, 1)
\end{ExampleCode}
\end{Examples}

