SVA: Error in svd((dats - rowMeans(dats))) : a dimension is zero
1
0
Entering edit mode
yi.huang ▴ 30
@yihuang-11146
Last seen 7.7 years ago

Hi all,

When running svaseq as "batch_sup_sva = svaseq(dat0,mod1,mod0,controls=controls,n.sv=1)$sv", I got an error:
Error in svd((dats - rowMeans(dats))) : a dimension is zero

Does anyone know how this problem was happened?

Many thanks,
Yi

 

sva • 5.8k views
ADD COMMENT
2
Entering edit mode
Jeff Leek ▴ 650
@jeff-leek-5015
Last seen 3.2 years ago
United States

Hi Yi, 

 

This could be happening for a couple of reasons: (1) you have a row or column that is all identical or all equal to zero, (2) because the controls vector is all FALSE or has only one TRUE in it because then you'd only have a vector not a matrix, or (3) you have a bunch of NAs in the matrix. If you could check and see that the data you are passing (looks like dat0) has two dimensions both greater than 1, that the controls vector has more than one TRUE, and that you have no constant or near constant rows or columns that would help diagnose the problem. 

 

Cheers

Jeff

ADD COMMENT
0
Entering edit mode

Thanks! I fixed the problem!

ADD REPLY

Login before adding your answer.

Traffic: 1043 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6