Entering edit mode
9.5 years ago
madkitty
▴
690
When following the WGCNA manual, I input the data in a data frame, and determine the soft threshold power. I get an error message when determining the soft threshold power .. which really prevents me from using WGCNA. the original matrix has 20,000 rows (genes) and 20 columns (samples).
library(WGCNA) options(stringsAsFactors = FALSE); enableWGCNAThreads() myData = read.csv("my_matrix.csv"); dataExpr0 = as.data.frame(t(myData)) powers = c(c(1:10), seq(from = 12, to=20, by=2)) sft = pickSoftThreshold(dataExpr0, powerVector = powers, verbose = 5) pickSoftThreshold: will use block size 29382. pickSoftThreshold: calculating connectivity for given powers... ..working on genes 1 through 29382 of 34688 Error in { : task 2 failed - "cannot allocate vector of size 1.9 Gb" In addition: There were 20 warnings (use warnings() to see them)
WGCNA is a hog when it comes to memory. I recall that there are some places where you can process things in blocks, you might see if you can do so at this stage. As is, the error is due to lack of memory.
What kind of filters you applied to decrease the dataset ?