git-svn-id: https://hedgehog.fhcrc.org/bioconductor/trunk/madman/Rpacks/preprocessCore@92139 bc3139a8-67e5-0310-9ffc-ced21a209358
... | ... |
@@ -12,7 +12,7 @@ rcModelPLM <- function(y,row.effects=NULL, input.scale=NULL){ |
12 | 12 |
if (length(row.effects) != nrow(y)){ |
13 | 13 |
stop("row.effects parameter should be same length as number of rows") |
14 | 14 |
} |
15 |
- if (abs(sum(row.effects)) > 10*.Machine$double.eps){ |
|
15 |
+ if (abs(sum(row.effects)) > length(row.effects)*.Machine$double.eps){ |
|
16 | 16 |
stop("row.effects should sum to zero") |
17 | 17 |
} |
18 | 18 |
.Call("R_rlm_rma_given_probe_effects",y,as.double(row.effects),PsiCode,PsiK,input.scale,PACKAGE="preprocessCore") |
... | ... |
@@ -48,7 +48,7 @@ rcModelWPLM <- function(y, w, row.effects=NULL, input.scale=NULL){ |
48 | 48 |
if (length(row.effects) != nrow(y)){ |
49 | 49 |
stop("row.effects parameter should be same length as number of rows") |
50 | 50 |
} |
51 |
- if (abs(sum(row.effects)) > 10*.Machine$double.eps){ |
|
51 |
+ if (abs(sum(row.effects)) > length(row.effects)*.Machine$double.eps){ |
|
52 | 52 |
stop("row.effects should sum to zero") |
53 | 53 |
} |
54 | 54 |
.Call("R_wrlm_rma_given_probe_effects",y,as.double(row.effects),PsiCode,PsiK,as.double(w),input.scale,PACKAGE="preprocessCore") |