[BioC] Problem with lmfit

David martin vilanew at gmail.com
Mon Aug 9 14:59:19 CEST 2010


Hello,
I have a strange problem while fitting a design to my data. Here is the 
output code. You can reproduce the problem by copy paste the code below.


 > design
   HEALTHY DISEASE
1       1      0
2       1      0
3       1      0
4       1      0
5       1      0
6       0      1
7       0      1
attr(,"assign")
[1] 1 1
attr(,"contrasts")
attr(,"contrasts")$groups
[1] "contr.treatment"

 > exprs(mydata.eset)
     healthy1      healthy2      healthy3      healthy4      N25 
disease1 disease2
1 25.92 25.66667 23.14667 26.28667 25.48667     21.19     20.81

 > lmFit(exprs(mydata.eset), design=design)
Error in fit$effects[(fit$rank + 1):narrays, , drop = FALSE] :
   incorrect number of dimensions


### Here is the code to reproduce the error
library(Biobase)
library(limma)
design <- matrix(c(1,0),ncol=2,nrow=5,byrow=T)
design <- rbind(design,c(0,1),c(0,1))
colnames(design) <- c("HEALTHY","DISEASE")
data <- matrix(c(25.92000, 25.66667, 23.14667, 26.28667, 25.48667 
,21.19000, 20.81000),nrow=1,ncol=7)
mydata.eset=new("ExpressionSet",exprs=data)
colnames(exprs(mydata.eset)) <- 
c("healthy1","healthy2","healthy3","healthy4","healthy5","disease1","disease2")
lmFit(mydata.eset, design=design)


thanks for leting me know,



More information about the Bioconductor mailing list