Single channel analysis of Agilent microarray data with Limma
From Mattick Lab
For two-channel analysis, refer to Two channel analysis of Agilent microarray data with Limma.
Note/Disclaimer: The instructions on this page are provided "as-is". They worked for my application and have helped many others on their way.
1. Launch R and load in the LIMMA library. The LIMMA user's guide, citation information, downloads and installation information is available from the Bioconductor website.
library(limma)
2. Read in your tab-delimited targets file, which contains both the names of your Agilent Feature Extraction raw data text files and the corresponding sample information. To describe 6 arrays that have been hybridised with two biological replicates of three different tissues, the format of the file should look something like this:
SampleNumber FileName Condition 1 US83403541_252144010018_S01_GE1-v5_10_Apr08_1_2.txt Brain 2 US83403541_252144010020_S01_GE1-v5_10_Apr08_1_1.txt Brain 3 US83403541_252144010021_S01_GE1-v5_10_Apr08_1_1.txt Lung 4 US83403541_252144010021_S01_GE1-v5_10_Apr08_1_2.txt Lung 5 US83403541_252144010023_S01_GE1-v5_10_Apr08_1_1.txt Liver 6 US83403541_252144010023_S01_GE1-v5_10_Apr08_1_2.txt Liver
targets <- readTargets("targets.txt")
3. Use LIMMA's read.maimages function to load your data into an RGList object. Remember to set the path to the location where your Agilent FE text files are stored.
x <- read.maimages(targets, path="somedirectory", source="agilent",green.only=TRUE)
4. Subtract the background (optional, but recommended).
y <- backgroundCorrect(x, method="normexp", offset=16)
5. Normalize between the arrays. Select a method appropriate for your data - see the user guide for details.
y <- normalizeBetweenArrays(y, method="quantile")
6. Use the avereps function to average replicate spots.
y.ave <- avereps(y, ID=y$genes$ProbeName)
7. Build the design matrix for the linear modelling function.
f <- factor(targets$Condition, levels = unique(targets$Condition)) design <- model.matrix(~0 + f) colnames(design) <- levels(f)
8. Apply the intensity values to lmFit.
fit <- lmFit(y.ave, design)
9. Create a contrast matrix. In this example, all combinations of contrasts can be set up as below.
contrast.matrix <- makeContrasts("Treatment1-Treatment2", "Treatment1-Treatment3", "Treatment2-Treatment1", levels=design)
10. Apply this contrast matrix to the modeled data and compute statistics for the data.
fit2 <- contrasts.fit(fit, contrast.matrix) fit2 <- eBayes(fit2)
11. Output the statistics for the dataset and write them to disk for further analysis.
output <- topTable(fit2, adjust="BH", coef="Treatment1-Treatment2", genelist=y.ave$genes, number=Inf) write.table(output, file="Treatment1_vs_Treatment.txt", sep="\t", quote=FALSE)
12. Repeat step 11 adjusting the coef value to output the various contrasts of interests setup in step 9.
Troubleshooting
If you receive the error below, it is likely that you have no replicate slides. Statistics cannot be calculated unless you have at least two replicates for each of your treatments.
No residual degrees of freedom in linear model fits
Acknowledgments
Thanks to Gordon Smyth for constructive comments regarding the instructions on this page.
If you have any questions, comments or suggestions for improvements, please let me know.

