diff --git a/R/getGlobalMeans.R b/R/getGlobalMeans.R index 3d58ae4e..09f1ae87 100644 --- a/R/getGlobalMeans.R +++ b/R/getGlobalMeans.R @@ -81,12 +81,12 @@ precomputeBootstrapMeans <- function( is.array <- assay == "array" if (!is.null(targets)) { - if (length(targets) < 5) stop("Need more than 5 samples for targeted bootstrapping to work.") + if (length(targets) < 5) stop("Need 5 or more samples for targeted bootstrapping to work.") obj <- getShrinkageTargets(obj, targets) } + assay.data <- .getAssay(obj, is.array) bootMean <- mclapply(1:num.bootstraps, function(b) { message("Working on bootstrap ", b) - assay.data <- .getAssay(obj, is.array) resamp.mat <- .resampleMatrix(assay.data) computeGlobalMean(resamp.mat) }, mc.cores = ifelse(parallel, num.cores, 1))