lmFit
lmFit is a core function in the limma package (Bioconductor) used for fitting linear models to gene expression data across samples. For each gene, it estimates coefficients corresponding to the effects specified by a design matrix, such as treatment versus control, timepoints, or other covariates. The input is typically an expression matrix with genes as rows and samples as columns, together with a design matrix that encodes the experimental design. The function can also incorporate information to account for correlation between samples in paired or blocked experiments.
lmFit returns an object (commonly of class MArrayLM) containing estimated coefficients, standard errors, residuals, and fitted
Common downstream steps include extracting results with topTable to obtain a ranked list of differential expression
lmFit supports complex experimental designs and can handle correlated samples through appropriate design specifications and correlation