First, thanks a lot for this wonderful package!
I am getting an error when generating an HTML report passing a ggplot2 theme to the DESeq2Report function. The source code (regionReport/R/DESeq2Report.R) shows that the error is due to the verification in line 175. Should the function ggplot2::is.theme() be used instead of is() in this line?
I'll appreciate you taking a look into this issue.
Best,
Hector
Detailed info
All the Bioconductor packages (including regionReport) were installed via BiocManager::install() using R (v4.3.1) installed via Homebrew.
Minimally reproducible example
library('pasilla')
#> Loading required package: DEXSeq
#> Loading required package: BiocParallel
#> Loading required package: Biobase
#> Loading required package: BiocGenerics
#>
#> Attaching package: 'BiocGenerics'
#> The following objects are masked from 'package:stats':
#>
#> IQR, mad, sd, var, xtabs
#> The following objects are masked from 'package:base':
#>
#> anyDuplicated, aperm, append, as.data.frame, basename, cbind,
#> colnames, dirname, do.call, duplicated, eval, evalq, Filter, Find,
#> get, grep, grepl, intersect, is.unsorted, lapply, Map, mapply,
#> match, mget, order, paste, pmax, pmax.int, pmin, pmin.int,
#> Position, rank, rbind, Reduce, rownames, sapply, setdiff, sort,
#> table, tapply, union, unique, unsplit, which.max, which.min
#> Welcome to Bioconductor
#>
#> Vignettes contain introductory material; view with
#> 'browseVignettes()'. To cite Bioconductor, see
#> 'citation("Biobase")', and for packages 'citation("pkgname")'.
#> Loading required package: SummarizedExperiment
#> Loading required package: MatrixGenerics
#> Loading required package: matrixStats
#>
#> Attaching package: 'matrixStats'
#> The following objects are masked from 'package:Biobase':
#>
#> anyMissing, rowMedians
#>
#> Attaching package: 'MatrixGenerics'
#> The following objects are masked from 'package:matrixStats':
#>
#> colAlls, colAnyNAs, colAnys, colAvgsPerRowSet, colCollapse,
#> colCounts, colCummaxs, colCummins, colCumprods, colCumsums,
#> colDiffs, colIQRDiffs, colIQRs, colLogSumExps, colMadDiffs,
#> colMads, colMaxs, colMeans2, colMedians, colMins, colOrderStats,
#> colProds, colQuantiles, colRanges, colRanks, colSdDiffs, colSds,
#> colSums2, colTabulates, colVarDiffs, colVars, colWeightedMads,
#> colWeightedMeans, colWeightedMedians, colWeightedSds,
#> colWeightedVars, rowAlls, rowAnyNAs, rowAnys, rowAvgsPerColSet,
#> rowCollapse, rowCounts, rowCummaxs, rowCummins, rowCumprods,
#> rowCumsums, rowDiffs, rowIQRDiffs, rowIQRs, rowLogSumExps,
#> rowMadDiffs, rowMads, rowMaxs, rowMeans2, rowMedians, rowMins,
#> rowOrderStats, rowProds, rowQuantiles, rowRanges, rowRanks,
#> rowSdDiffs, rowSds, rowSums2, rowTabulates, rowVarDiffs, rowVars,
#> rowWeightedMads, rowWeightedMeans, rowWeightedMedians,
#> rowWeightedSds, rowWeightedVars
#> The following object is masked from 'package:Biobase':
#>
#> rowMedians
#> Loading required package: GenomicRanges
#> Loading required package: stats4
#> Loading required package: S4Vectors
#>
#> Attaching package: 'S4Vectors'
#> The following object is masked from 'package:utils':
#>
#> findMatches
#> The following objects are masked from 'package:base':
#>
#> expand.grid, I, unname
#> Loading required package: IRanges
#> Loading required package: GenomeInfoDb
#> Loading required package: DESeq2
#> Loading required package: AnnotationDbi
#> Loading required package: RColorBrewer
library('DESeq2')
library('ggplot2')
library('regionReport')
data("pasillaDEXSeqDataSet")
countData <- counts(dxd)
colData <- colData(dxd)[, c('condition', 'type')]
# Create DESeqDataSet object from the pasilla package
dds <- DESeqDataSetFromMatrix(countData = countData,
colData = colData,
design = ~ condition)
# Perform the differential expression analysis
dds <- DESeq(dds)
#> estimating size factors
#> estimating dispersions
#> gene-wise dispersion estimates
#> mean-dispersion relationship
#> final dispersion estimates
#> fitting model and testing
#> -- replacing outliers and refitting for 1 genes
#> -- DESeq argument 'minReplicatesForReplace' = 7
#> -- original counts are preserved in counts(dds)
#> estimating dispersions
#> fitting model and testing
dir.create('DESeq2-example', showWarnings = FALSE, recursive = TRUE)
# Create the HTML report
report <- DESeq2Report(dds, project = 'DESeq2 HTML report',
intgroup = c('condition', 'type'), outdir = 'DESeq2-example',
output = 'index', theme = theme_bw())
#> Error in is(theme, c("theme", "gg")): length(class2) == 1L is not TRUE
Hello,
First, thanks a lot for this wonderful package! I am getting an error when generating an HTML report passing a ggplot2 theme to the
DESeq2Report
function. The source code (regionReport/R/DESeq2Report.R
) shows that the error is due to the verification in line 175. Should the functionggplot2::is.theme()
be used instead ofis()
in this line?I'll appreciate you taking a look into this issue.
Best, Hector
Detailed info
All the Bioconductor packages (including
regionReport
) were installed viaBiocManager::install()
using R (v4.3.1) installed via Homebrew.Minimally reproducible example
R session info