% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/stats_tests.R
\name{run.limma.de}
\alias{run.limma.de}
\title{Run Differential Expression Analysis Using limma}
\usage{
run.limma.de(geo, condition.col = "disease.state", adjust.method = "BH")
}
\arguments{
\item{geo}{Named list as returned by \code{extract.expression()}, containing
at minimum \code{$expression} (probe x sample matrix) and
\code{$phenotype} (sample metadata data frame).}

\item{condition.col}{Character. Name of the column in \code{geo$phenotype}
to use as the grouping variable. Default is \code{"disease.state"}.}

\item{adjust.method}{Character. P-value correction method passed to
\code{limma::topTable()}. Default is \code{"BH"} (Benjamini-Hochberg FDR).}
}
\value{
A data frame (TopTable) with one row per probe, sorted by evidence
of differential expression, containing:
\describe{
\item{logFC}{Log2 fold-change between conditions.}
\item{AveExpr}{Average log2 expression across all samples.}
\item{t}{Moderated t-statistic.}
\item{P.Value}{Raw p-value.}
\item{adj.P.Val}{FDR-adjusted p-value (BH by default).}
\item{B}{Log-odds that the gene is differentially expressed.}
}
}
\description{
Performs genome-wide differential expression analysis across all probes
using the limma linear modeling framework. This is the recommended approach
for microarray data from GEO, as it borrows variance information across
genes to produce more stable estimates than gene-by-gene t-tests.
}
\details{
Unlike running \code{analyze.gene()} on each probe individually, limma fits
a linear model to all probes simultaneously and applies empirical Bayes
shrinkage to the variance estimates. This stabilizes results for genes with
few observations and is the standard method for microarray DE analysis.

The returned TopTable is the primary input for downstream functions such as
\code{volcano.plot()} and \code{run.gsea()}, and can be filtered by
\code{adj.P.Val} and \code{logFC} thresholds to define a gene signature.
}
\examples{
\donttest{
geo <- extract.expression(load.geo.soft(accession = "GDS3268", log.transform = TRUE))
de.results <- run.limma.de(geo, condition.col = "disease.state")
head(de.results)
}

}
