Search
Question: Problem with WGCNA - Module-trait relationship
0
12 months ago by
amoltej10
Australia
amoltej10 wrote:

Hello everyone,

I am trying to run the WGCNA on my data set of 87 samples.

First 2 steps executed successfully. In the third step when running following commands I am getting all the "NA"s in the output.

moduleTraitCor = cor(MEs, datTraits, use = "p")
moduleTraitPvalue = corPvalueStudent(moduleTraitCor, nSamples)

please find input files for these commands below

modified 12 months ago by Lluís R370 • written 12 months ago by amoltej10
0
12 months ago by
Lluís R370
European Union
Lluís R370 wrote:

The first line calculates the correlation of each trait with the egienvalue of each module, the second line gives you the p-value of said correlations for a given number of p-values. I advise you to use a function named somehow like corAndPvalue which gives both correlations and p-values takeing into account the number of samples with information for each trait

Hi Lluis,

Thanks for the reply but the result is still same. I suspect for some reason correlation is not calculating or calculating it to 0 for all the values

What code do you use for "the third step"? Are there any NA in your input data? Did you use the "complete" observations option to calculate the correlations?

I am using this code for third step - https://labs.genetics.ucla.edu/horvath/CoexpressionNetwork/Rpackages/WGCNA/Tutorials/FemaleLiver-03-relateModsToExt.pdf

Yes, I am using complete observations to calculate correlations. There are no NA's in the input dataset for these commands. you can check input files from my question.