adjacency function of WGCNA
4
0
Entering edit mode
wlnjseu • 0
@wlnjseu-11337
Last seen 7.7 years ago

Hi everyone,

I can run 

sft = pickSoftThreshold(cd4_exp, powerVector = powers, verbose = 5, networkType="signed", corFnc= "bicor",corOptions = list(use = 'p', maxPOutliers = 0.1))

 

However, It is wrong for adjacency

adjacencymatrix = adjacency(cd4_exp, power=softpower, corFnc="bicor", type="signed",  corOptions = "use = 'p', maxPOutliers = 0.1")

Error in bicor(datExpr, use = "p", maxPOutliers = 0.1) : 

long vectors (argument 8) are not supported in .Fortran

 

 Could you give me some advice?

 

Thank you very much.

Best Wishes!

Lei

wgcna • 3.3k views
ADD COMMENT
1
Entering edit mode
wlnjseu • 0
@wlnjseu-11337
Last seen 7.7 years ago

 

 

Hi Peter

For the function blockwiseModules, I found that different maximum block size influence the number of modules.  I am not sure whether I should set maximum block size more bigger, and the number of block more less.  For example, there are 50300 genes. I set maximum block   size with 5000 and 10 blocks, or 30000 and 2 blocks. 

Thanks again. 

Lei

 

 

 

 

 

ADD COMMENT
0
Entering edit mode
Hi, please note that blocks and modules are very different. Blocks are determined by blocksize and are meant to ensure that the analysis fits into available RAM. The blocks are not biologically meaningful except the code tries to keep correlated genes within the same block (as far as possible, given the constraints of the block size). Modules should be biologically meaningful and they will be fairly similar (but not the same) irrespective of block size as long as the blocks are large enough to cover entire modules. Please read WGCNA tutorial I, section 2c, https://labs.genetics.ucla.edu/horvath/CoexpressionNetwork/Rpackages/WGCNA/Tutorials/index.html . Set the block size as large as you can given the RAM you have and the restriction to no more than 46k genes per block, so in your case you will want maxBlockSize of say 40000 and you will get two blocks. Then you run module analysis and see how many modules you get. Peter
ADD REPLY
0
Entering edit mode
@peter-langfelder-4469
Last seen 7 weeks ago
United States

At present WGCNA cannot analyze more than about 46300 (more precisely, sqrt(2^31)) variables in one block. If you have more than 46300 variables, you can either

  1. Reduce the number of variables (e.g., filter out low-expressed or non-varying microarray probes)
  2. Split the data into blocks and run the analysis in each block separately. This is implemented in the function blockwiseModules but it can also be done using step-by-step analysis. You can use the function projectiveKMeans to split data into blocks, then you can run the adjacency function in each block separately.

 

Peter

ADD COMMENT
0
Entering edit mode
wlnjseu • 0
@wlnjseu-11337
Last seen 7.7 years ago

 

 

 

Hi Peter,

Thank your reply.

I want to use step-by-step analysis. The projectiveKMeans is a variant of K-means clustering for expression data. I am not sure (1) K value (2) next step after I run the adjacency function in each block separately. whether I will conduct TOMsimilarity and 1-TOM in each block separately.

TOM = TOMsimilarity(adjacency, TOMType="signed");
dissTOM = 1-TOM​

Could you give me some examples? https://labs.genetics.ucla.edu/horvath/htdocs/CoexpressionNetwork/

I still can not find an example using  projectiveKMeans to conduct step-by-step analysis.

Thanks!

Lei

 

 

 

 

ADD COMMENT
0
Entering edit mode
@peter-langfelder-4469
Last seen 7 weeks ago
United States

Sorry, I don't have tutorials of projectiveKMeans. You don't need to specify the number of centers, you need the maximum block size  (set it to 35000 or so and you will get two blocks). The number of centers will be chosen automatically.

I always recommend using the function blockwiseModules first; only if the function cannot do what you like, should you invest time into studying the individual analysis steps which do take a bit to figure out.

If you insist on doing the analysis manually, please read the help for projectiveKMeans; the output contains component clusters which gives the block assignment for each gene. You can then run the manual network analysis in each block. You can try studying the code for blockwiseModules in WGCNA to see how the individual calculations mesh together.

Peter

ADD COMMENT

Login before adding your answer.

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