while doing co-expression network analysis, I am getting an error
1
0
Entering edit mode
Rishav ▴ 20
@rishav-25031
Last seen 13 months 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)
> HBV <- read.csv("HBV.csv",row.names=1)
> 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 • 1.1k views
ADD COMMENT
0
Entering edit mode
Kevin Blighe ★ 3.9k
@kevin
Last seen 1 day ago
Republic of Ireland

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

ADD COMMENT
0
Entering edit mode

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

ADD REPLY
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.

ADD REPLY
0
Entering edit mode

Please follow this link : https://horvath.genetics.ucla.edu/html/CoexpressionNetwork/Rpackages/WGCNA/Tutorials/FemaleLiver-01-dataInput.pdf I am first trying to preprocess and clean my data.

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
ADD REPLY
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.

ADD REPLY
0
Entering edit mode

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

ADD REPLY

Login before adding your answer.

Traffic: 946 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