\HeaderA{03.ReadingData}{Reading Microarray Data from Files}{03.ReadingData}
\keyword{documentation}{03.ReadingData}
\begin{Description}\relax
This help page gives an overview of LIMMA functions used to read data from files.
\end{Description}
\begin{Section}{Reading Target Information}
The function \code{\LinkA{readTargets}{readTargets}} is designed to help with organizing information about which RNA sample is hybridized to each channel on each array and which files store information for each array.
\end{Section}
\begin{Section}{Reading Intensity Data}
The first step in a microarray data analysis is to read into R the intensity data for each array provided by an image analysis program.
This is done using the function \code{\LinkA{read.maimages}{read.maimages}}.

\code{\LinkA{read.maimages}{read.maimages}} optionally constructs quality weights for each spot using quality functions listed in \LinkA{QualityWeights}{QualityWeights}.

\code{read.maimages} produces an \code{RGList} object and stores only the information required from each image analysis output file.
\code{\LinkA{read.maimages}{read.maimages}} uses utility functions \code{\LinkA{removeExt}{removeExt}}, \code{\LinkA{read.imagene}{read.imagene}} and \code{\LinkA{read.columns}{read.columns}}.
There are also a series of utility functions which read the header information from image output files including \code{\LinkA{readGPRHeader}{readGPRHeader}}, \code{\LinkA{readImaGeneHeader}{readImaGeneHeader}} and \code{\LinkA{readGenericHeader}{readGenericHeader}}.

The function \LinkA{as.MAList}{as.MAList} can be used to convert a \code{marrayNorm} object to an \code{MAList} object if the data was read and normalized using the marray and marrayNorm packages.
\end{Section}
\begin{Section}{Reading the Gene List}
Most image analysis software programs provide gene IDs as part of the intensity output files, for example GenePix, Imagene and the Stanford Microarray Database do this.
In other cases the probe ID and annotation information may be in a separate file.
The most common format for the probe annotation file is the GenePix Array List (GAL) file format.
The function \code{\LinkA{readGAL}{readGAL}} reads information from a GAL file and produces a data frame with standard column names.

The function \code{\LinkA{getLayout}{getLayout}} extracts from the GAL-file data frame the print layout information for a spotted array.
The functions \code{\LinkA{gridr}{gridr}}, \code{\LinkA{gridc}{gridc}}, \code{\LinkA{spotr}{spotr}} and \code{\LinkA{spotc}{spotc}} use the extracted layout to compute grid positions and spot positions within each grid for each spot.
The function \code{\LinkA{printorder}{printorder}} calculates the printorder, plate number and plate row and column position for each spot given information about the printing process.
The utility function \code{\LinkA{getSpacing}{getSpacing}} converts character strings specifying spacings of duplicate spots to numeric values.

The Australian Genome Research Facility in Australia often produces GAL files with composite probe IDs or names consisting of multiple strings separated by a delimiter.
These can be separated into name and annotation information using \code{\LinkA{strsplit2}{strsplit2}}.

If each probe is printed more than once of the arrays in a regular pattern, then \code{\LinkA{uniquegenelist}{uniquegenelist}} will remove duplicate names from the gal-file or gene list.
\end{Section}
\begin{Section}{Identifying Control Spots}
The functions \code{\LinkA{readSpotTypes}{readSpotTypes}} and \code{\LinkA{controlStatus}{controlStatus}} assist with separating control spots from ordinary genes in the analysis and data exploration.
\end{Section}
\begin{Section}{Manipulating Data Objects}
\code{\LinkA{cbind}{cbind}}, \code{\LinkA{rbind}{rbind}}, \code{\LinkA{merge}{merge}} allow different \code{RGList} or \code{MAList} objects to be combined.
\code{cbind} combines data from different arrays assuming the layout of the arrays to be the same.
\code{merge} can combine data even when the order of the probes on the arrays has changed.
\code{merge} uses utility function \code{\LinkA{makeUnique}{makeUnique}}.
\end{Section}
\begin{Author}\relax
Gordon Smyth
\end{Author}

