Browse code

Merge pull request #89 from HenrikBengtsson/bugfix/if-error

BUG FIX: if (rezero) { } was called with length(rezero) > 1

Michael authored on 08/09/2017 19:12:33 • GitHub committed on 08/09/2017 19:12:33
Showing 1 changed files

... ...
@@ -172,11 +172,11 @@ setMethod(
172 172
                         return_norm = c("no", "in_memory", "hdf5"),
173 173
                         hdf5file,
174 174
                         bpparam=BiocParallel::bpparam()) {
175
-    
176
-    
177
-    rezero = (zero %in% c("preadjust","strong"))
178
-    fixzero = (zero %in% c("postadjust","strong"))
179
-    
175
+
176
+    zero <- match.arg(zero)
177
+    rezero <- (zero %in% c("preadjust","strong"))
178
+    fixzero <- (zero %in% c("postadjust","strong"))
179
+
180 180
     if(x@is_log) {
181 181
       stop("At the moment, scone is implemented only for non-log counts.")
182 182
     }