diff --git a/.github/workflows/check-bioc.yml b/.github/workflows/check-bioc.yml index e32789e2..b0a02516 100644 --- a/.github/workflows/check-bioc.yml +++ b/.github/workflows/check-bioc.yml @@ -52,10 +52,11 @@ jobs: fail-fast: false matrix: config: - - { os: ubuntu-latest, r: '4.2', bioc: '3.16', cont: "bioconductor/bioconductor_docker:RELEASE_3_16", rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest" } - - { os: ubuntu-latest, r: 'next', bioc: '3.17', cont: "bioconductor/bioconductor_docker:RELEASE_3_17", rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest" } - - { os: macOS-latest, r: '4.2', bioc: '3.16'} - - { os: windows-latest, r: '4.2', bioc: '3.16'} + # This needs to be updated after each Bioconductor release. Please make sure we have the matching R and Bioc versions in it. + - { os: ubuntu-latest, r: '4.3', bioc: '3.18', cont: "bioconductor/bioconductor_docker:RELEASE_3_18", rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest" } + - { os: ubuntu-latest, r: 'next', bioc: '3.19', cont: "bioconductor/bioconductor_docker:devel", rspm: "https://packagemanager.rstudio.com/cran/__linux__/focal/latest" } + - { os: macOS-latest, r: '4.3', bioc: '3.18'} + - { os: windows-latest, r: '4.3', bioc: '3.18'} ## Check https://github.com/r-lib/actions/tree/master/examples ## for examples using the http-user-agent env: @@ -249,7 +250,7 @@ jobs: rcmdcheck::rcmdcheck( args = c("--no-manual", "--no-vignettes", "--timings"), build_args = c("--no-manual", "--keep-empty-dirs", "--no-resave-data"), - error_on = "error", + error_on = "warning", check_dir = "check" ) shell: Rscript {0} @@ -313,7 +314,7 @@ jobs: if: failure() uses: actions/upload-artifact@master with: - name: ${{ runner.os }}-biocversion-RELEASE_3_16-r-4.2-results + name: ${{ runner.os }}-biocversion-RELEASE_3_18-r-4.3-results path: check ## Note that DOCKER_PASSWORD is really a token for your dockerhub diff --git a/DESCRIPTION b/DESCRIPTION index 1fbc6703..018f3010 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -2,14 +2,17 @@ Package: FRASER Type: Package Title: Find RAre Splicing Events in RNA-Seq Data Version: 1.99.3 -Date: 2022-11-25 +Date: 2024-02-11 Authors@R: c( person("Christian", "Mertes", role=c("aut", "cre"), - email="mertes@in.tum.de"), - person("Ines", "Scheller", role=c("aut"), email="scheller@in.tum.de"), - person("Karoline", "Lutz", role=c("aut")), - person("Vicente", "Yepez", role=c("ctb"), email="yepez@in.tum.de"), - person("Julien", "Gagneur", role=c("aut"), email="gagneur@in.tum.de")) + email="mertes@in.tum.de", comment=c(ORCID="0000-0002-1091-205X")), + person("Ines", "Scheller", role=c("aut"), email="scheller@in.tum.de", + comment=c(ORCID="0000-0003-4533-7857")), + person("Karoline", "Lutz", role=c("ctb"), email="lutzk@in.tum.de"), + person("Vicente", "Yepez", role=c("aut"), email="yepez@in.tum.de", + comment=c(ORCID="0000-0001-7916-3643")), + person("Julien", "Gagneur", role=c("aut"), email="gagneur@in.tum.de", + comment=c(ORCID="0000-0002-8924-8365"))) Description: Detection of rare aberrant splicing events in transcriptome profiles. Read count ratio expectations are modeled by an autoencoder to control for confounding factors in the data. Given these expectations, @@ -28,8 +31,8 @@ biocViews: Coverage License: MIT + file LICENSE URL: https://github.com/gagneurlab/FRASER -BugRepots: https://github.com/gagneurlab/FRASER/issues -RoxygenNote: 7.2.3 +BugReports: https://github.com/gagneurlab/FRASER/issues +RoxygenNote: 7.3.1 Encoding: UTF-8 VignetteBuilder: knitr Depends: @@ -75,7 +78,8 @@ Imports: tools, utils, VGAM -Suggests: +Suggests: + magick, BiocStyle, knitr, rmarkdown, diff --git a/R/AllGenerics.R b/R/AllGenerics.R index 2e17f04e..180863f3 100644 --- a/R/AllGenerics.R +++ b/R/AllGenerics.R @@ -234,8 +234,11 @@ setReplaceMethod("nonSplicedReads", "FraserDataSet", function(object, value){ #' @param x A \code{FraserDataSet} object #' @param i A integer vector to subset the rows/ranges #' @param j A integer vector to subset the columns/samples -#' @param by a character (j or ss) definig if we subset by +#' @param by a character (j or ss) defining if we subset by #' junctions or splice sites +#' @param ... Parameters currently not used or passed on +#' @param drop No dimension reduction is done. And the \code{drop} +#' parameter is currently not used at all. #' @return A subsetted \code{FraserDataSet} object #' @examples #' fds <- createTestFraserDataSet() @@ -244,7 +247,7 @@ setReplaceMethod("nonSplicedReads", "FraserDataSet", function(object, value){ #' fds[1:10,by="ss"] #' #' @rdname subset -subset.FRASER <- function(x, i, j, by=c("j", "ss")){ +subset.FRASER <- function(x, i, j, by=c("j", "ss"), ..., drop=FALSE){ if(length(by) == 1){ by <- whichReadType(x, by) } @@ -292,14 +295,14 @@ subset.FRASER <- function(x, i, j, by=c("j", "ss")){ idxNSR <- rowData(x, type="ss")[['spliceSiteID']] %in% ssIdx # subset it - nsrObj <- nsrObj[idxNSR,j] + nsrObj <- nsrObj[idxNSR,j,drop=FALSE] } # subset the inheritate SE object if(length(x) == 0){ i <- NULL } - subX <- as(as(x, "RangedSummarizedExperiment")[i,j], "FraserDataSet") + subX <- as(as(x, "RangedSummarizedExperiment")[i,j,drop=FALSE], "FraserDataSet") # create new FraserDataSet object newx <- new("FraserDataSet", @@ -315,7 +318,7 @@ subset.FRASER <- function(x, i, j, by=c("j", "ss")){ } #' @rdname subset #' @export -setMethod("[", c("FraserDataSet", "ANY", "ANY"), subset.FRASER) +setMethod("[", c("FraserDataSet", "ANY", "ANY", drop="ANY"), subset.FRASER) #' diff --git a/man/subset.Rd b/man/subset.Rd index 034e934b..f034f714 100644 --- a/man/subset.Rd +++ b/man/subset.Rd @@ -5,9 +5,9 @@ \alias{[,FraserDataSet,ANY,ANY,ANY-method} \title{Subsetting by indices for junctions} \usage{ -\method{subset}{FRASER}(x, i, j, by = c("j", "ss")) +\method{subset}{FRASER}(x, i, j, by = c("j", "ss"), ..., drop = FALSE) -\S4method{[}{FraserDataSet,ANY,ANY,ANY}(x, i, j, by = c("j", "ss")) +\S4method{[}{FraserDataSet,ANY,ANY,ANY}(x, i, j, by = c("j", "ss"), ..., drop = FALSE) } \arguments{ \item{x}{A \code{FraserDataSet} object} @@ -16,8 +16,13 @@ \item{j}{A integer vector to subset the columns/samples} -\item{by}{a character (j or ss) definig if we subset by +\item{by}{a character (j or ss) defining if we subset by junctions or splice sites} + +\item{...}{Parameters currently not used or passed on} + +\item{drop}{No dimension reduction is done. And the \code{drop} +parameter is currently not used at all.} } \value{ A subsetted \code{FraserDataSet} object diff --git a/src/Makevars b/src/Makevars index 74e22156..7fb56432 100644 --- a/src/Makevars +++ b/src/Makevars @@ -1,4 +1,2 @@ -CXX_STD = CXX11 - PKG_CXXFLAGS = $(SHLIB_OPENMP_CXXFLAGS) -DARMA_DONT_USE_OPENMP PKG_LIBS = $(SHLIB_OPENMP_CXXFLAGS) $(LAPACK_LIBS) $(BLAS_LIBS) $(FLIBS) diff --git a/src/Makevars.win b/src/Makevars.win index 74e22156..7fb56432 100644 --- a/src/Makevars.win +++ b/src/Makevars.win @@ -1,4 +1,2 @@ -CXX_STD = CXX11 - PKG_CXXFLAGS = $(SHLIB_OPENMP_CXXFLAGS) -DARMA_DONT_USE_OPENMP PKG_LIBS = $(SHLIB_OPENMP_CXXFLAGS) $(LAPACK_LIBS) $(BLAS_LIBS) $(FLIBS) diff --git a/tests/testthat/test_getter_setter.R b/tests/testthat/test_getter_setter.R index 5db58672..36304edd 100644 --- a/tests/testthat/test_getter_setter.R +++ b/tests/testthat/test_getter_setter.R @@ -12,3 +12,12 @@ test_that("counts", { expect_equal(counts(fds, type="theta", side='other'), N(fds, "theta") - K(fds, "theta")) }) + +test_that("generic functions", { + # test that the correct functions are selected and called + methDef <- selectMethod("[", c("FraserDataSet", "ANY", "ANY", drop="ANY")) + expect_equal(slot(methDef, "defined")[["x"]], "FraserDataSet") + methDef <- selectMethod("[", + c("FraserDataSet", "ANY", "ANY", drop="missing")) + expect_equal(slot(methDef, "defined")[["x"]], "FraserDataSet") +}) diff --git a/vignettes/FRASER.Rnw b/vignettes/FRASER.Rnw index 5e5fe1f6..4c51170c 100644 --- a/vignettes/FRASER.Rnw +++ b/vignettes/FRASER.Rnw @@ -452,7 +452,7 @@ After looking at the expression distribution between filtered and unfiltered junctions, we can now subset the dataset: <>= -fds_filtered <- fds[mcols(fds, type="j")[,"passed"],] +fds_filtered <- fds[mcols(fds, type="j")[,"passed"]] fds_filtered # filtered_fds not further used for this tutorial because the example dataset # is otherwise too small