\HeaderA{bkgdCorrect}{Background correction of intensity values.}{bkgdCorrect}
\keyword{documentation}{bkgdCorrect}
\keyword{utilities}{bkgdCorrect}
\begin{Description}\relax
Takes a Codelink object with Spot mean and Bkgd median values
and corrects applying one of the methods available.
\end{Description}
\begin{Usage}
\begin{verbatim}
  bkgdCorrect(object, method = "half", preserve = FALSE, verbose = FALSE,
    offset = 0)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{object}] character; an object of class "Codelink".
\item[\code{method}] character; the correction method to use, one of "none", "subtract", "half" and "normexp".
\item[\code{preserve}] logical; if Smean and Bmedian slots should be preserved.
\item[\code{verbose}] logical; if TRUE print some information with method normexp.
\item[\code{offset}] numeric; value to add to intensities.
\end{ldescription}
\end{Arguments}
\begin{Details}\relax
Available methods are:
. none: left intensities untouched.
. subtract: simple subtraction of Bkgd median from Spot mean.
. half: the same as above but aboid negative values setting all intensity
values below zero to 0.5.
. normexp: apply normexp background adjustment from package limma.
\end{Details}
\begin{Value}
An object of class Codelink with corrected intensity values, that is
Ri slot.
\end{Value}
\begin{Author}\relax
Diego Diez
\end{Author}
\begin{Examples}
\begin{ExampleCode}
## Not run: 
    data(codelink.example)
    codelink.example <- bkgdCorrect(codelink.example, method = "half")
## End(Not run)
\end{ExampleCode}
\end{Examples}

