Skip to content

Commit

Permalink
fix bug in VS()
Browse files Browse the repository at this point in the history
  • Loading branch information
zhizuio committed Sep 27, 2024
1 parent d3c4ca1 commit c82df11
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ URL: https://github.com/ocbe-uio/BayesSurvive
BugReports: https://github.com/ocbe-uio/BayesSurvive/issues
License: GPL-3
VignetteBuilder: knitr
Depends: R (>= 4.0)
Depends: R (>= 4.4.0)
Encoding: UTF-8
RoxygenNote: 7.3.2
LinkingTo: Rcpp, RcppArmadillo, testthat
Expand All @@ -22,7 +22,7 @@ Imports: Rcpp, ggplot2, GGally, mvtnorm, survival, riskRegression,
Suggests: knitr, testthat
LazyData: true
NeedsCompilation: yes
Packaged: 2024-09-27 15:26:16 UTC; zhiz
Packaged: 2024-09-27 19:57:03 UTC; zhiz
Author: Zhi Zhao [aut, cre],
Waldir Leoncio [aut],
Katrin Madjar [aut],
Expand Down
4 changes: 3 additions & 1 deletion R/VS.R
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,9 @@ VS <- function(x, method = "FDR", threshold = NA, subgroup = 1) {
stop("The list input has to consist of matrices and/or arrays!")
}
# If the input is a matrix or array, reformat it to be an list
x <- list(x)
if (!is.list(x)) {
x <- list(x)
}
}
if (!method %in% c("CI", "SNC", "MPM", "FDR")) { # "SNC-BIC",
stop("'method' should be one of c('CI', 'SNC', 'MPM', 'FDR')!")
Expand Down

0 comments on commit c82df11

Please sign in to comment.