vidger icon indicating copy to clipboard operation
vidger copied to clipboard

Future support for limma-voom pipeline: vsFourWay()

Open nztao opened this issue 3 years ago • 0 comments

The vsFourWay function does not support eBayes transformed DGEList-objects from the limma-voom pipeline. For example, I followed a demonstration similar to this posted guide:

> # limma-voom DGEList-objects do not work with `vsFourWay()`
> #Packages needed
> if (!require("BiocManager", quietly = TRUE))
>     install.packages("BiocManager")
> 
> BiocManager::install(c("limma", "edgeR", "vidger"))
> 
> library(limma)
> library(edgeR)
> library(vidger)
> 
> #Load and read in example RNAseq123 data from wd()
> #https://github.com/hasaru-k/GlimmaV2/blob/master/inst/RNAseq123/
> dge <- readRDS("dge.rds")
> design <- readRDS(
>   system.file("RNAseq123/design.rds", package = "Glimma"))
> contr.matrix <- readRDS(
>   system.file("RNAseq123/contr.matrix.rds", package = "Glimma"))
> 
> #Using limma-voom to calculate test statistics for each gene.
> v <- voom(dge, design)
> vfit <- lmFit(v, design)
> vfit <- contrasts.fit(vfit, contrasts = contr.matrix)
> efit <- eBayes(vfit)
> 
> # Example incompatibility with limma-voom 
> vsFourWay(
>     x = 'LP', y = 'ML', control = 'Basal', data = dge,
>     d.factor = NULL, type = 'edger', padj = 0.05, x.lim = NULL,
>     y.lim = NULL, lfc = NULL, legend = TRUE, title = TRUE, grid = TRUE
> )

When directly referencing the dge or efit objects, I get the following error:

Error in exactTest(data, pair = c(control, x)) : specified dispersion not found in object

The vsFourWay function appears to only recognize the estimateDisp transformation for DGEList-objects processed using the edgeR quasi-likelihood pipeline. Will there be future support for DGEList-objects using limma-voom DE analysis?

Thank you!

nztao avatar Sep 05 '22 08:09 nztao