Hi,
I am trying to find the p-values for golub data. I have loaded the data as follows:
library(multtest)
library(annotate)
library(limma)
dat<-golub[,]
dat<-as.data.frame(dat)
The first 27 columns are controls and the remaining 11 are tests. I want to calculate the p-values using the eBayes(0 method in the limma package. The following is my code:
design<-as.data.frame(cbind(dat[,1:27], dat[,28:38]))
fit<-lmFit(dat,design)
However, I am getting the following error:
Error in lm.fit(design, t(M)) : incompatible dimensions
When I checked, the dim of design and dat, they are of same dimension as shown below:
dim(design)
[1] 3051 38
dim(dat)
[1] 3051 38
Thanks
Hello Sean, Thanks for the reply. Now the error is gone. When I tried to get the p-Values using .p.Values<-fit3$p.value[,2] , I am getting the following error: Error in fit3$p.value[, 2] : subscript out of bounds Thanks
I have found the p values as follows. p.Values<-fit3$p.value Thanks
You may want to use topTable() for this type of thing.