Single sample analysis can be done in edgeR, while it is deprecated in DNASeq2 in 2018 probably (if you can use old DESeq version then it will work in single sample also).
For egdeR you just do
library(edgeR) setwd() rawdata <- read.delim("filename", check.names=FALSE, stringsAsFactors=FALSE) ngenes <- 10000 #no. of genes nsamples <- 2 #no. of sample Counts <- matrix(rnbinom(ngenes*nsamples,mu=5,size=2),ngenes,nsamples) rownames(Counts) <- rawdata[,1] y <- DGEList(counts=Counts, group=c("Normal", "Cancer")) y$samples y<-calcNormFactors(y) y$design <- model.matrix(~group,y$samples) y<-estimateDisp(y, design=y$design) y$fit<-glmQLFit(y, design=y$design) topTags(glmQLFTest(y$fit,coef=2),n=Inf) d <- topTags(glmQLFTest(y$fit,coef=2),n=Inf) d write.table(d, file = "Result.txt", row.names=TRUE, sep="t")
Remember edgeR comparison is alphabetically like Cancer vs. Normal (C come before N). you can also use the design file and put it as design$condition. But for simplicity, I would recommend the log FC would work better than using any library. Just divide (take mean if more than one sample in a group) the tumor sample count from the normal sample and change it into log scale since all libraries are worthless due to the absence of outlier calling or p-value or p.adst etc.
Read more here: Source link