while doing co-expression network analysis, I am getting an error
1
0
Entering edit mode
Rishav • 0
@rishav-25031
Last seen 3 hours ago
Patna

Hello everyone, I am trying to do a co-expression network analysis of my RNA seq data in R, but I am getting an error. Please help me to understand why my data got terminated.


# >library(WGCNA)
> options(stringsAsFactors = FALSE)
> dim(HBV)
[1] 26692    23
> names(HBV)
[1] "A" "B" "C" "D" "E" "F" "G" "H" "I" "J" "K" "L" "M" "N" "O" "P" "Q" "R" "S"
[20] "T" "U" "V" "W"
> gsg = goodSamplesGenes(HBV, verbose = 3)
Flagging genes and samples with too many missing values...
..step 1
> gsg\$allOK
[1] TRUE
> sampleTree = hclust(dist(HBV), method = "average")

# Terminated

RNASeqData • 80 views
0
Entering edit mode
@kevin
Last seen 13 minutes ago
United States

Hi, you are most likely running out of memory while R attempts to construct the distance tree via dist(). Can you confirm what are your computer's specifications?

Note: It is implied via your code that you are aiming to use WGCNA. If this is the case, then please follow the standard tutorial(s): https://horvath.genetics.ucla.edu/html/CoexpressionNetwork/Rpackages/WGCNA/Tutorials/

Kevin

0
Entering edit mode

I am following the standard tutorial and from there I have used these codes.

0
Entering edit mode

Can you please elaborate? - which part of the tutorial? You neither answered my first question, but that is okay. It just means that I / we have less ability to assist.

0
Entering edit mode

This is my system's memory information.

H/W path             Device       Class          Description


============================================================

/0/0                              memory         64KiB BIOS

/0/4/5                            memory         64KiB L1 cache

/0/4/6                            memory         3MiB L2 cache

/0/c                              memory         3584MiB System Memory

/0/c/0                            memory         2GiB DIMM SDRAM Synchronous

0
Entering edit mode

Thanks for sharing the information. It seems that your computer's memory is relatively low, compared to other computers. This may not be enough to generate the required distance matrix, and this is what is likely causing the crash / error.

You could try to generate the distance tree via pvclust, as this uses bootstrapping; however, with this amount of memory at your disposal, you are going to frequently run into problems in the future.

You could also try to skip this part of the WGCNA workflow. I think that the other WGCNA functions make better use of memory.

0
Entering edit mode

Thanks for your patience and the information I will soon upgrade my system.