I'm running DE analyses on RNA-Seq data of 4 leukemia patients. by using the 'convert' package and the 'as' function I convert the data to 'ExpressionSet' format. then I run the 'GOexpress' package, but when I reach the 'GO_analyse' function I get the following error:
"Error in aggregate.data.frame(mf[1L], mf[-1L], FUN = FUN, ...) :
no rows to aggregate"
You can see the code I'm running below:
library("DESeq2") list.files(directory) sampleFiles<- c("N1.counts","N3.counts", "L2.counts","L3.counts") sampleNames <- c("Normal1","Normal3","Leukemia2","Leukemia3") sampleCondition <- c("control","control","treated","treated") sampleTable <- data.frame(sampleName = sampleNames, fileName = sampleFiles, condition = sampleCondition) ddsHTSeq <- DESeqDataSetFromHTSeqCount(sampleTable = sampleTable, design = ~ condition) library(GOexpress) data(AlvMac) AlvMac library("Biobase") library(convert) z=as(ddsHTSeq,'ExpressionSet') z AlvMac=z
It does not make any differences in producing error running AlvMac=z or not. I ran the code using #AlvMac=z, but I faced the same error.
head(pData(z)) head(rownames(exprs(z))) is.factor(z$condition) z$condition z$condition <- factor(z$condition) AlvMac_results <- GO_analyse(eSet = z, f = "condition",biomart_dataset= "hsapiens_gene_ensembl") Error in aggregate.data.frame(mf[1L], mf[-1L], FUN = FUN, ...) : no rows to aggregate
Any idea to help me understand where the problem is or how to solve it would be appreciated.