jtleek / sva-devel

28 stars 45 forks source link

coerce dat into matrix & address zero variance genes within any single batch #35

Closed zhangyuqing closed 4 years ago

zhangyuqing commented 5 years ago

To address issue #24 , I modified ComBat to explicitly coerce the input variable dat into a matrix.

Also, there were some concerns about ComBat failing with zero variance genes which did not get resolved. Now ComBat first looks for genes with zero variance in any of the batches. Then it ignores them, do the adjustment on the remaining genes, and add them back in at the end of the function.