\HeaderA{expressopdnn}{Position Dependant Nearest Neighbors model for affy}{expressopdnn}
\aliasA{affypdnn}{expressopdnn}{affypdnn}
\aliasA{pdnn.scalevalue.exprSet}{expressopdnn}{pdnn.scalevalue.exprSet}
\keyword{manip}{expressopdnn}
\begin{Description}\relax
a wrapper to perform the PDNN method.
\end{Description}
\begin{Usage}
\begin{verbatim}
pdnn.scalevalue.exprSet(eset, scale.to=500)
expressopdnn(abatch,
      # background correction
             bg.correct = FALSE,
             bgcorrect.method = NULL,
             bgcorrect.param = list(),
      # normalize
             normalize = FALSE,
             normalize.method = NULL,
             normalize.param = list(),
              pmcorrect.method = c("pdnn", "pdnnpredict"),
      # pdnn
             findparams.param = list(),          
      # expression values
             summary.subset = NULL,
      # PDNN expression values scaling
             eset.normalize = TRUE,
             scale.to = 500,
      # misc.
             verbose = TRUE,
             widget = FALSE)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{abatch}] object of \code{\LinkA{AffyBatch-class}{AffyBatch.Rdash.class}}
\item[\code{bg.correct}] a boolean to express whether background correction
is wanted or not.
\item[\code{bgcorrect.method}] the name of the background adjustment method
\item[\code{bgcorrect.param}] a list of parameters for bgcorrect.method (if
needed/wanted)
\item[\code{eset}] An object of \code{\LinkA{exprSet-class}{exprSet.Rdash.class}}
\item[\code{normalize}] normalization step wished or not.
\item[\code{normalize.method}] the normalization method to use
\item[\code{normalize.param}] a list of parameters to be passed to the
normalization method (if wanted).
\item[\code{pmcorrect.method}] the name of the PM adjustement method (only
two choices here, default to 'pdnn').
\item[\code{findparams.param}] a list of parameters to be passed to \code{find.params.pdnn}
\item[\code{eset.normalize}] is any normalization step on expression values
to be performed
\item[\code{scale.to}] a value to scale against.
\item[\code{summary.subset}] a list of 'affyids'. If \code{NULL}, a
expression summary value is computed for everything on the chip.
\item[\code{verbose}] logical value. If \code{TRUE} it writes out some
messages.
\item[\code{widget}] a boolean to specify the use of widgets (the package
tkWidget is required). NOTE: this not yet implemented !
\end{ldescription}
\end{Arguments}
\begin{Details}\relax
\code{expressopdnn} is very similar to \code{\LinkA{expresso}{expresso}}. It is
mainly a wrapper around the pre-processing steps `background
correction', `normalization', `perfect match correction' and
the PDNN method to compute expression values (see the first
reference for more details about the preprocessing steps and
and the second reference for further details about the PDNN method).

The wrapper \code{expresso} has no way to handle easily the
computation of chip-wide results that have to be used during
the \code{computeExprSet} step. An easy way to overcome this
was to write this simple wrapper.

\code{pdnn.scalevalue} is performed after the expression values
have computed to somehow `normalize' the values between different
chips. When setting \code{normalize} to \code{TRUE} this step
might be considered unnecessary (and the \code{eset.normalize} set
to \code{FALSE}).
\end{Details}
\begin{Value}
An object of \code{\LinkA{exprsSet-class}{exprsSet.Rdash.class}}, with an attribute
\code{pps.warnings} as returned by the method \code{\LinkA{computeExprSet}{computeExprSet}}.
\end{Value}
\begin{SeeAlso}\relax
\code{\LinkA{expresso}{expresso}} and \code{\LinkA{computeExprVal.method.pdnn}{computeExprVal.method.pdnn}}
\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}

## load pre-computed parameters
data(hgu95av2.pdnn.params)

library(affydata)
data(Dilution)

## one CEL to go faster
afbatch <- Dilution[, 1]

## Take only few IDs (the 10 first)
ids <- ls(getCdfInfo(afbatch))[1:10]
eset <- expressopdnn(afbatch, bg.correct=FALSE,
                     normalize=FALSE,
                     findparams.param=list(params.chiptype=hgu95av2.pdnn.params,
                                           give.warnings=FALSE),
                     summary.subset=ids) 

\end{ExampleCode}
\end{Examples}

