\HeaderA{exprSet}{Class for Microarray Data and Methods for Processing Them}{exprSet}
\aliasA{abstract,exprSet-method}{exprSet}{abstract,exprSet.Rdash.method}
\aliasA{annotation,exprSet-method}{exprSet}{annotation,exprSet.Rdash.method}
\aliasA{annotation<-,exprSet,ANY-method}{exprSet}{annotation<.Rdash.,exprSet,ANY.Rdash.method}
\aliasA{as.data.frame.exprSet}{exprSet}{as.data.frame.exprSet}
\aliasA{as.data.frame.exprSet,exprSet-method}{exprSet}{as.data.frame.exprSet,exprSet.Rdash.method}
\aliasA{assayData,exprSet-method}{exprSet}{assayData,exprSet.Rdash.method}
\aliasA{class:exprSet}{exprSet}{class:exprSet}
\aliasA{description,exprSet-method}{exprSet}{description,exprSet.Rdash.method}
\aliasA{description<-,exprSet,ANY-method}{exprSet}{description<.Rdash.,exprSet,ANY.Rdash.method}
\aliasA{esApply,exprSet-method}{exprSet}{esApply,exprSet.Rdash.method}
\aliasA{exprs,exprSet-method}{exprSet}{exprs,exprSet.Rdash.method}
\aliasA{exprs2excel}{exprSet}{exprs2excel}
\aliasA{exprs2excel,exprSet-method}{exprSet}{exprs2excel,exprSet.Rdash.method}
\aliasA{exprs<-,exprSet,ANY-method}{exprSet}{exprs<.Rdash.,exprSet,ANY.Rdash.method}
\aliasA{exprSet-class}{exprSet}{exprSet.Rdash.class}
\aliasA{featureNames,exprSet-method}{exprSet}{featureNames,exprSet.Rdash.method}
\aliasA{featureNames<-,exprSet-method}{exprSet}{featureNames<.Rdash.,exprSet.Rdash.method}
\aliasA{geneNames,exprSet-method}{exprSet}{geneNames,exprSet.Rdash.method}
\aliasA{geneNames<-,exprSet,ANY-method}{exprSet}{geneNames<.Rdash.,exprSet,ANY.Rdash.method}
\aliasA{initialize,exprSet-method}{exprSet}{initialize,exprSet.Rdash.method}
\aliasA{intitialize,exprSet-method}{exprSet}{intitialize,exprSet.Rdash.method}
\aliasA{iter,exprSet,character,function-method}{exprSet}{iter,exprSet,character,function.Rdash.method}
\aliasA{iter,exprSet,missing,function-method}{exprSet}{iter,exprSet,missing,function.Rdash.method}
\aliasA{iter,exprSet,missing,list-method}{exprSet}{iter,exprSet,missing,list.Rdash.method}
\aliasA{notes,exprSet-method}{exprSet}{notes,exprSet.Rdash.method}
\aliasA{notes<-,exprSet,ANY-method}{exprSet}{notes<.Rdash.,exprSet,ANY.Rdash.method}
\aliasA{sampleNames,exprSet-method}{exprSet}{sampleNames,exprSet.Rdash.method}
\aliasA{sampleNames<-,exprSet,ANY-method}{exprSet}{sampleNames<.Rdash.,exprSet,ANY.Rdash.method}
\aliasA{se.exprs,exprSet-method}{exprSet}{se.exprs,exprSet.Rdash.method}
\aliasA{se.exprs<-,exprSet-method}{exprSet}{se.exprs<.Rdash.,exprSet.Rdash.method}
\aliasA{show,exprSet-method}{exprSet}{show,exprSet.Rdash.method}
\aliasA{split}{exprSet}{split}
\aliasA{split,exprSet,factor,missing-method}{exprSet}{split,exprSet,factor,missing.Rdash.method}
\aliasA{split,exprSet,vector,missing-method}{exprSet}{split,exprSet,vector,missing.Rdash.method}
\aliasA{update2MIAME}{exprSet}{update2MIAME}
\aliasA{update2MIAME,exprSet-method}{exprSet}{update2MIAME,exprSet.Rdash.method}
\aliasA{updateObject,exprSet-method}{exprSet}{updateObject,exprSet.Rdash.method}
\aliasA{write.exprs}{exprSet}{write.exprs}
\aliasA{write.exprs,exprSet-method}{exprSet}{write.exprs,exprSet.Rdash.method}
\aliasA{[,exprSet-method}{exprSet}{[,exprSet.Rdash.method}
\keyword{methods}{exprSet}
\keyword{classes}{exprSet}
\begin{Description}\relax
This is a class representation for microarray data
\end{Description}
\begin{Section}{Extends}
Directly extends class \code{\LinkA{annotatedDataset}{annotatedDataset}}.
\end{Section}
\begin{Section}{Creating Objects}
\code{ new('exprSet', exprs = [exprMatrix], se.exprs = [exprMatrix], phenoData = [phenoData], annotation = [character], description = [characterORMIAME], notes = [character])}
\end{Section}
\begin{Section}{Slots}
Derived from \code{\LinkA{annotatedDataset}{annotatedDataset}}:
\describe{
\item[\code{reporterInfo}] class:\code{data.frameOrNULL}
\item[\code{phenoData}:] Object of class 'phenoData' containing the patient (or case) level data. The columns of the pData slot of this entity represent variables and the rows represent patients or cases. 
}
Introduced in \code{exprSet}:
\describe{
\item[\code{exprs}:] Object of class 'exprMatrix'. The observed expression levels. This is a matrix with columns representing patients or cases and rows representing genes. 
\item[\code{se.exprs}:] Object of class 'exprMatrix'. This is a matrix of the same dimensions as \code{exprs} which contains standard error estimates for the estimated expression levels. 
\item[\code{annotation}] A character string identifying the annotation that may be used for the \code{exprSet} instance.
\item[\code{description}:] Object of class 'characterORMIAME'. For compatibility with previous version of this class description can also be a 'character'. The clase \code{characterOrMIAME} has been defined just for this.
\item[\code{notes}:] Object of class 'character' of explanatory text 
}
\end{Section}
\begin{Section}{Methods}
Derived from \code{\LinkA{annotatedDataset}{annotatedDataset}}:
\describe{
\item[\code{\$(exprSet)} and \code{\$(exprSet, value)<-}] An old-style method. It is \code{pData(eset)[[as.character(val)]]} which does not quite have the right semantics but it is close. This operator extracts the named component of the \code{pData} slot in \code{phenoData}.
\item[\code{[[(index)} and \code{[[(index, value)<-}:] see \code{\LinkA{annotatedDataset}{annotatedDataset}}
\item[\code{phenoData(exprSet)} and \code{phenoData(exprSet, value)<-}] see \code{\LinkA{annotatedDataset}{annotatedDataset}}
\item[\code{reporterInfo(exprSet)} and \code{reporterInfo(exprSet, value)<-}] see \code{\LinkA{annotatedDataset}{annotatedDataset}}
\item[\code{pData(exprSet)} and \code{pData(exprSet, value)<-}] see \code{\LinkA{annotatedDataset}{annotatedDataset}}
\item[\code{varLabels(exprSet)}] see \code{\LinkA{annotatedDataset}{annotatedDataset}}
}
Class-specific methods:
\describe{
\item[\code{update2MIAME(exprSet)}:] Converts \code{exprSet}s from previous versions, that have a \code{character} in description to an object that has an instance of the class \code{MIAME} in the description slot. The old description is stored in the \code{title} slot. If the object already has a \code{MIAME} description the same object is returned.
\item[\code{assayData(exprSet)}:] Method to access \code{exprs} slot
\item[\code{exprs(exprSet)} and \code{exprs(exprSet)<-}:] Methods to access/update \code{exprs} slot 
\item[\code{se.exprs(exprSet)} and \code{se.exprs(exprSet)<-}:] Methods to access/update \code{se.exprs} slot 
\item[\code{description(exprSet)} and \code{description(exprSet, value)<-}:] Methods to access/update \code{description} slot 
\item[\code{annotation(exprSet)} and \code{annotation(exprSet, value)<-}:] Methods to access/update \code{annotation} slot
\item[\code{notes(exprSet)} and \code{notes(exprSet, value)<-}:] Methods to access/update \code{notes} slot 
\item[\code{abstract(exprSet)}:] Not documented: \code{function(object) abstract(description(object))}
\item[\code{sampleNames(exprSet)} and \code{sampleNames(exprSet, value)<-}:] Methods to access/update \code{dimnames} of the \code{exprs} slot 
\item[\code{geneNames(exprSet)} and \code{geneNames(exprSet, value)<-}:] Methods to access/update \code{row.names} of the \code{exprs} slot - gene names 
\item[\code{featureNames(exprSet)} and \code{featureNames(exprSet, value)<-}:] Methods to access/update \code{row.names} of the \code{exprs} slot; use \code{featureNames} in preference to \code{geneNames}, to allow easier transition to new Biobase classes like \code{\LinkA{ExpressionSet-class}{ExpressionSet.Rdash.class}}.
\item[\code{esApply(exprSet, MARGIN, FUN, ...)}] 'apply'-like function to conveniently operate on \code{exprSet} objects. See \code{\LinkA{esApply}{esApply}}.
\item[\code{write.exprs(exprSet,...)}:] Writes the expression levels to file. It takes the same arguments as \code{\LinkA{write.table}{write.table}}. If called with no arguments it is equivalent to \code{write.table(exprs(exprSet),file="tmp.txt",quote=FALSE,sep="\bsl{}t")}.
\item[\code{exprs2excel(exprSet,...)}:] Writes the expression levels to \code{csv} file. This file will open nicely in excel. It takes the same arguments as \code{\LinkA{write.table}{write.table}}. If called with no arguments it is equivalent to \code{write.table(exprs(exprSet),file="tmp.csv", sep = ",", col.names = NA)}.
\item[\code{as.data.frame.exprSet(exprSet, row.names = NA, optional = NA)}:] Converts \code{exprSet} into a \code{data.frame}. In the return value, the first column is called \code{exprs} and contains the values returned by the method \code{exprs()}. The second column is called genenames and contains the values returned by the method \code{geneNames()}. The other columns will depend on the contents of the \code{\LinkA{phenoData}{phenoData}} slot.
}
Iterator-series methods:\\
This is a set of methods to iterate over different types of objects. The behaviour of the methods is similar to that of the \code{apply} family.
\describe{
\item[\code{iter(exprSet, missing, function)}:] An iterator over genes. Returns the result of applying \code{function} to the matrix of expressions on margin 1 (see \code{apply})
\item[\code{iter(exprSet, missing, list)}:] A multi-iterator over genes. Concatenates result of applying each function in the list \code{list} in a matrix (assumes result of each function evaluation is a scalar).
\item[\code{iter(exprSet, character, function)}:] An iterator over genes. \code{function} is assumed to have arguments x and y; the pData element named by covlab will be bound to x, the gene expression values will be iteratively bound to y
}
Split-series methods:
\describe{
\item[\code{split(exprSet, factor)}:] See method for \code{vector}
\item[\code{split(exprSet, vector)}:] Splits the exprSet. The returned value is a list, each component of which is an \code{exprSet}. If the length of \code{vector} is a divisor of the number of rows of the phenoData data frame then the split is made on this.
}
Standard generic methods:
\describe{
\item[\code{updateObject(object, ..., verbose=FALSE)}] Update instance to current version, if necessary. See \code{\LinkA{updateObject}{updateObject}}
\item[\code{isCurrent(object)}] Determine whether version of object is current. See \code{\LinkA{isCurrent}{isCurrent}}
\item[\code{isVersioned(object)}] Determine whether object contains a 'version' string describing its structure . See \code{\LinkA{isVersioned}{isVersioned}}
\item[\code{show(exprSet)}:] Renders information about the exprSet in a concise way on stdout. 
\item[\code{[(exprSet)}:] A subset operator. Ensures that both \code{exprs} and \code{phenoData} are subset properly.
\item[\code{validObject(exprSet)}:] Validity-checking method,
ensuring the number and names of \code{phenoData} rows match the
number and names of \code{exprs} columns
}
\end{Section}
\begin{SeeAlso}\relax
\code{\LinkA{MIAME}{MIAME}}, \code{\LinkA{annotatedDataset}{annotatedDataset}}, \code{\LinkA{phenoData}{phenoData}}, \code{\LinkA{class:exprMatrix}{class:exprMatrix}}, \code{\LinkA{class:characterORMIAME}{class:characterORMIAME}}, \code{\LinkA{read.exprSet}{read.exprSet}}, \code{\LinkA{esApply}{esApply}}
\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}
  data(geneData)
  data(geneCov)
  covdesc<- list("Covariate 1", "Covariate 2", "Covariate 3")
  names(covdesc) <- names(geneCov)
  pdata <- new("phenoData", pData=geneCov, varLabels=covdesc)
  pdata[1,]
  pdata[,2]

  expr <- new("exprSet", exprs=geneData, phenoData=pdata)
  expr
  expr[,1:10]
  expr[,1]
  expr[1,]
  expr[1,1]
  expr[1:100,]
  expr[1:44,c(2,4,6)]
  Means <- iter(expr, f=mean)

  chkdich <- function(x) if(length(unique(x))!=2) stop("x not dichotomous")
  mytt <- function(x,y) {
     chkdich(x)
     d <- split(y,x)
     t.test(d[[1]],d[[2]])$p.val
  }

  Tpvals <- iter(expr, "cov1", mytt )

  sp1 <- split(expr, c(1,2))
  sp2 <- split(expr, c(rep(1,6), rep(2,7)))

  sampleNames(expr)
  sampleNames(expr) <- letters
  featureNames(expr)[1:10]

  # as.data.frame.exprSet - example
  data(sample.exprSet)
  sd.genes <- esApply(sample.exprSet, 1, sd)
  dataf <- as.data.frame(sample.exprSet)
  dataf <- cbind(dataf, sd.genes=rep(unname(sd.genes), length=nrow(dataf)))
  coplot(sd.genes ~ exprs | sex+type, data=dataf)

  # update existing exprSet-like object
  data(sample.exprSet)
  updateObject(sample.exprSet) # to match class definition of same (exprSet) class
  expressionSet <- as(sample.exprSet, "ExpressionSet") # to different class
\end{ExampleCode}
\end{Examples}

