[BioC] limma : design matrix and topTable M values

Sue Jones s.jones at sussex.ac.uk
Fri Jun 16 15:39:21 CEST 2006



I am analysing affymetrix chips. I have 4 ethanol treated chips and 5 
water treated chips. I wanted to find which genes are differentially 
expressed when exposed to ethanol. Using the limma using guide I have got 
this code so far

====================================================
files <- c("E2h_1.CEL",  "E2h_2.CEL", "E2h_3.CEL", "E2h_4.CEL","W05h_1.CEL", "W0h_1.CEL", "W2h_1.CEL", "W2h_2.CEL", "W4h_1.CEL")
Data <- ReadAffy(filenames = files)
Data_gcrma <- gcrma(Data)
type <- c("eth","eth","eth","eth","wat", "wat", "wat", "wat", "wat")
design <- model.matrix(~factor(type))
colnames(design) <- c("Eth", "Wat_vs_Eth")
fit<-lmFit(Data_gcrma,design)
fit <- eBayes(fit)
options(digits=2)
topTable(fit,coef=2, n=50, adjust="fdr")
============================================================

printing the design matrix gives

   Eth Wat_vs_Eth
1   1          0
2   1          0
3   1          0
4   1          0
5   1          1
6   1          1
7   1          1
8   1          1
9   1          1
attr(,"assign")
[1] 0 1
attr(,"contrasts")
attr(,"contrasts")$"factor(type)"
[1] "contr.treatment"

What I want to know is do I have the design matrix the correct way round?

Are the positive M values printed from topTable those upregulated on 
exposure to ethanol compared to water?


Cheers

Sue



More information about the Bioconductor mailing list