pcaMethods
pcaMethods copied to clipboard
Running llsImpute never ends - but it does end my memory
Hey there!
I am trying to run llsImpute on my spectracounts, with the following commands:
library("vsn")
library("pcaMethods")
pdata = as.matrix(read.table('spectracounts.tsv.txt', sep='\t', h=T, row.names=1))
pdata[pdata==0] = NA
norm = justvsn(ExpressionSet(pdata))
imputed = llsImpute(t(exprs(norm)), allVariables = TRUE)
However, the last command never ends (been running for four hours at this point), and drains around 50 Gb of memory for dealing with a matrix of a few Kb. What is happening here?
At first I tried running that command as imputed = llsImpute(t(exprs(norm))), but it always failed with
Error in svd(X) : infinite or missing values in 'x'
In addition: Warning message:
In llsImpute(t(exprs(norm))) :
Less than 50% of the genes are complete, consider using allVariables = TRUE
Limiting the matrix I seem to have stumbled upon the reason, which I found I had already reported one year ago (although I didn't follow on the issue, my bad). Running
pdata = pdata[1:1000,]
norm = justvsn(ExpressionSet(pdata))
imputed = llsImpute(t(exprs(norm)), allVariables = TRUE)
Finishes successfully, but calling imputed to see the results gives me
> imputed
Variables
Samples
Error in (function (classes, fdef, mtable) :
unable to find an inherited method for function ‘nObs’ for signature ‘"nniRes"’