Dear expert,
I have got count data with htseq-count. In my study, there is no groups. Only one group, I do not want do deferential analsyis.
How can I normalize my count data?
I use code as follow, but get error.
workdir <- "~/projects/all/analysis/rnaseq/deseq2/results"
setwd(workdir)
library('DESeq2')
dat.dir<-"~/projects/all/analysis/rnaseq/count/gene/"
countFiles <- list.files(dat.dir,pattern =".txt")
library(stringr)
sampleName <- str_replace(countFiles, ".txt", "")
sampleCondition <- rep("all",length(sampleName))
sampleTable<-data.frame(sampleName=sampleName, fileName=countFiles,condition=sampleCondition)
ddsHTSeq<-DESeqDataSetFromHTSeqCount(sampleTable=sampleTable, directory=dat.dir, design=~condition)
Error in `contrasts<-`(`*tmp*`, value = contr.funs[1 + isOF[nn]]) :
contrasts can be applied only to factors with 2 or more levels