This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Differential Gene Analysis

I had generated volcano plot by using limma package, but how to get a list of a gene that is upregulated or downregulated separately.

rna-seq chip-seq rna-seq r

1 answer

Look at decideTests:

An object of class TestResults. This is essentially a numeric matrix with elements -1, 0 or 1 depending on whether each t-statistic is classified as significantly negative, not significant or significantly positive.

Or look at the logFC column from topTable.

This is the command I am using to generate volcano plot so now which command should i use to get down and up-regulated gene.

Differential expression analysis with limma

library(Biobase)

library(GEOquery)

library(limma)

load series and platform data from GEO

gset <- getGEO("GSE34747", GSEMatrix =TRUE, AnnotGPL=FALSE)

if (length(gset) > 1) idx <- grep("GPL15069", attr(gset, "names")) else idx <- 1

gset <- gset[[idx]]

make proper column names to match toptable

fvarLabels(gset) <- make.names(fvarLabels(gset))

group names for all samples

gsms <- "000111"

sml <- c()

for (i in 1:nchar(gsms)) { sml[i] <- substr(gsms,i,i) }

log2 transform

ex <- exprs(gset) qx <- as.numeric(quantile(ex, c(0., 0.25, 0.5, 0.75, 0.99, 1.0), na.rm=T))

LogC <- (qx[5] > 100) ||

      (qx[6]-qx[1] > 50 && qx[2] > 0) ||

      (qx[2] > 0 && qx[2] < 1 && qx[4] > 1 && qx[4] < 2)

if (LogC) { ex[which(ex <= 0)] <- NaN

exprs(gset) <- log2(ex) }

set up the data and proceed with analysis

sml <- paste("G", sml, sep="") # set group names

fl <- as.factor(sml)

gset$description <- fl

design <- model.matrix(~ description + 0, gset)

colnames(design) <- levels(fl)

fit <- lmFit(gset, design)

cont.matrix <- makeContrasts(G1-G0, levels=design)

fit2 <- contrasts.fit(fit, cont.matrix)

fit2 <- eBayes(fit2, 0.01)

volcanoplot(fit2)

Log in to answer this question.