[BioC] how to deal with technical replicates in Limma?

Lana Teixeira Fernandes lana.teixeira at cresa.uab.cat
Tue Sep 4 18:49:46 CEST 2007


Hi,

I am working with Porcine Affymetrix in an experiment with technical replicates. I have 4 animals (2 control and 2 infected) and for each of them I have a technical replicate. Could somebody help me on how to include the technical replicates in a correct way in the model using eBayes analysis in the Limma package, please? I am not sure if the following script is correct:

library(affy)
Data.mes <- ReadAffy()
phenoData(Data.mes)
pd.mes <- data.frame(control = c(1,1,1,1,2,2,2,2), replica = c(1,1,2,2,3,3,4,4))
rownames(pd.mes) <- sampleNames(Data.mes)
vl <- list(control = "1 is control, 2 is infected", replica = "1 is N1, 2 is N2, 3 is N3, and 4 is N4")
phenoData(Data.mes) <- new("phenoData", pData = pd.mes, varLabels = vl)
library(affyPLM)
Data.mes.rma <- rma(Data.mes)
e.mes.rma <- exprs(Data.mes.rma)
library(limma)
Data.mes.rma <- rma(Data.mes)
design <- model.matrix(~factor(Data.mes.rma$control)+ Data.mes.rma$replica)
fit <- lmFit(Data.mes.rma, design)
ebayes <- eBayes(fit)
tab <- topTable(ebayes, coef = 2, adjust = "fdr", n=24123)

Thanks in advance,

Lana Teixeira Fernandes
PhD student
Centre de Recerca en Sanitat Animal (CreSA)
Barcelona - Spain
Tel.: +34 93 581 45 61     Fax: +34 93 581 44 90
lana.teixeira at cresa.uab.cat       www.cresa.es 



More information about the Bioconductor mailing list