git-svn-id: file:///home/git/hedgehog.fhcrc.org/bioconductor/trunk/madman/Rpacks/preprocessCore@51158 bc3139a8-67e5-0310-9ffc-ced21a209358
... | ... |
@@ -134,7 +134,7 @@ void medianlog(double *data, int rows, int cols, double *results, double *result |
134 | 134 |
|
135 | 135 |
for (j=0; j < cols; j++){ |
136 | 136 |
for (i = 0; i < rows; i++){ |
137 |
- buffer[i] = log2(data[j*rows + i]); |
|
137 |
+ buffer[i] = log(data[j*rows + i])/log(2.0); |
|
138 | 138 |
} |
139 | 139 |
results[j] = median_log(buffer,rows); |
140 | 140 |
resultsSE[j] = R_NaReal; |
... | ... |
@@ -151,7 +151,7 @@ void medianlog_no_copy(double *data, int rows, int cols, double *results, double |
151 | 151 |
|
152 | 152 |
for (j=0; j < cols; j++){ |
153 | 153 |
for (i = 0; i < rows; i++){ |
154 |
- data[j*rows + i]= log2(data[j*rows + i]); |
|
154 |
+ data[j*rows + i]= log(data[j*rows + i])/log(2.0); |
|
155 | 155 |
} |
156 | 156 |
results[j] = median_log(&data[j*rows],rows); |
157 | 157 |
resultsSE[j] = R_NaReal; |