Answers.Body: <p>Looks like a bug in the code which I will try to hunt down and fix. In the meantime, I would suggest playing with maxBlockSize argument to blockwiseModules. Try increasing it as much as your available RAM allows (see the paragraph "A second word of caution concerning block size" on page 6 of <a href="https://horvath.genetics.ucla.edu/html/CoexpressionNetwork/Rpackages/WGCNA/Tutorials/FemaleLiver-02-networkConstr-blockwise.pdf" rel="nofollow noreferrer">WGCNA tutorial I, section 2c</a>, for some guidance on how to set maxBlockSize). Hope this helps.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-06T18:19:25.430Z
Answers.Text: Thank you so much for looking over this for me, I very much appreciate your time and effort. I will try and play around with the maxBlockSize as suggested. Thank you kindly
Answers.UserDisplayName: holly
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-28T00:09:21.440Z
Answers.Text: I also got this error:
  Did you manage to solve the issue @PeterLangfelder > > sessionInfo() R version 3.5.1 (2018-07-02) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 7 x64 (build > 7601) Service Pack 1 > > Matrix products: default > > locale: [1] LC_COLLATE=English_New Zealand.1252 LC_CTYPE=English_New > Zealand.1252 LC_MONETARY=English_New Zealand.1252 [4] LC_NUMERIC=C > LC_TIME=English_New Zealand.1252 > > attached base packages: [1] stats graphics grDevices utils > datasets methods base > > other attached packages: [1] WGCNA_1.67 fastcluster_1.1.25 > dynamicTreeCut_1.63-
Answers.UserDisplayName: Zoe Ward
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-29T01:30:07.433Z
Answers.Text: Please try the newest version (1.68) of WGCNA from CRAN. This bug should be fixed.
Answers.UserDisplayName: Peter Langfelder
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-04T16:40:15.360Z
Answers.LastActivityDate: 2019-05-04T16:40:15.360Z
Answers.UserDisplayName: Peter Langfelder
Body: <p>I am using WGCNA and code has worked with no problems with some of my datasets however with most recent attempt when completing gene network &amp; identification of modules. I get following error code... </p>
  
  <pre><code>net__30= blockwiseModules(t5, power=6,
                                TOMType = "signed", minModuleSize=30,
                                reassignThreshold =0, mergeCutHeight = 0.25,
                                numericLabels = TRUE, pamRespectsDendro = FALSE,
                                saveTOMs = TRUE,
                                saveTOMFileBase = "PBCreponseTOMB",
                                verbose= 3)
  </code></pre>
  
  <p>I come up with error code saying: </p>
  
  <pre><code>            Number of items to replace is not a multiple of replacement length.
  </code></pre>
  
  <p>Does anyone please know what this indicts to? I have looked on all the WGCNA tutorial pages but cannot find this error message anywhere.</p>
  
  <p>Thank you kindly </p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-05-02T16:13:07.953Z
Comments.Text: Could be a bug in the code. You will need to provide more detail. When you get the error, type traceback() and post what you get. Also, post the output of `sessionInfo()`.
Comments.UserDisplayName: Peter Langfelder
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-05-03T08:17:43.743Z
Comments.Text: Error code:     Error in clustDist[ii, ] <- if (intNetworkType == 1) 1 - abs(cr1) else 1 -  :
  
    number of items to replace is not a multiple of replacement length
Comments.UserDisplayName: holly
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-05-03T08:20:19.393Z
Comments.Text: sessionInfo()    R version 3.5.1 (2018-07-02)
  Platform: x86_64-pc-linux-gnu (64-bit)
  Running under: Ubuntu 16.04.5 LTS
  Matrix products: default
Comments.UserDisplayName: holly
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-05-03T08:22:15.113Z
Comments.Text: 3: sizeRestrictedClusterMerge(datExpr, clusters = membership, clusterSizes = clusterSizes, centers = centers, maxSize = preferredSize, networkType = networkType, verbose = verbose, indent = indent) 2: projectiveKMeans(datExpr, preferredSize = maxBlockSize, checkData = FALSE, sizePenaltyPower = blockSizePenaltyPower, nCenters = nPreclusteringCenters,  verbose = verbose - 2, indent = indent + 1)
Comments.UserDisplayName: holly
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-05-03T08:22:20.903Z
Comments.Text: 1: blockwiseModules(B_CC_4, power = 6, TOMType = "signed", minModuleSize = 10,       reassignThreshold = 0, mergeCutHeight = 0.25, numericLabels = TRUE, pamRespectsDendro = FALSE, saveTOMs = TRUE, saveTOMFileBase = "PBCreponseTOMB",
         verbose = 3)
Comments.UserDisplayName: holly
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-05-03T08:23:11.030Z
Comments.Text: I can't add more of the sessionInfo() as too many characters.. can you let me know which parts are key to review. Thank you so much for your kind assistance. I am abit lost with the error and re-run over and over again and re-formatted my raw data, cant see any errors there, thank you
Comments.UserDisplayName: holly
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-05-06T14:48:22.480Z
Comments.Text: @holly You can [edit] your question to include these details and other that might be needed to give a good answer to your question (And help future readers to find it, as comments are not indexed by searcher)
Comments.UserDisplayName: llrs
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-05-06T23:03:45.007Z
Comments.Text: Please try installing and using this development version of WGCNA: https://www.dropbox.com/s/fuu73li4ajjfr3z/WGCNA_1.67-90.tar.gz?dl=0 and see if it solves the issue. Thanks again for reporting the issue.
Comments.UserDisplayName: Peter Langfelder
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-05-07T11:30:13.150Z
Comments.Text: Thank you kindly for all your kind help, very much appreciate it
Comments.UserDisplayName: holly
Tags: <r><wgcna>
Title: WGCNA error codes in Network Construction & moduel detection
ThreadText: # WGCNA error codes in Network Construction & moduel detection
  
  (Asked by: username_0 on 2019-05-02)
  
  I am using WGCNA and code has worked with no problems with some of my datasets however with most recent attempt when completing gene network & identification of modules. I get following error code...
  
  ```
  net__30= blockwiseModules(t5, power=6,
                                TOMType = "signed", minModuleSize=30,
                                reassignThreshold =0, mergeCutHeight = 0.25,
                                numericLabels = TRUE, pamRespectsDendro = FALSE,
                                saveTOMs = TRUE,
                                saveTOMFileBase = "PBCreponseTOMB",
                                verbose= 3)
  
  ```
  
  I come up with error code saying:
  
  ```
              Number of items to replace is not a multiple of replacement length.
  
  ```
  
  Does anyone please know what this indicts to? I have looked on all the WGCNA tutorial pages but cannot find this error message anywhere.
  
  Thank you kindly
  
  **Tags:** r, wgcna
  
  > **Comments:**
  > **username_1**: Could be a bug in the code. You will need to provide more detail. When you get the error, type traceback() and post what you get. Also, post the output of `sessionInfo()`.  
  > **username_0**: Error code:     Error in clustDist[ii, ] <- if (intNetworkType == 1) 1 - abs(cr1) else 1 -  :    number of items to replace is not a multiple of replacement length  
  > **username_0**: sessionInfo()    R version 3.5.1 (2018-07-02) Platform: x86_64-pc-linux-gnu (64-bit) Running under: Ubuntu 16.04.5 LTS Matrix products: default  
  > **username_0**: 3: sizeRestrictedClusterMerge(datExpr, clusters = membership, clusterSizes = clusterSizes, centers = centers, maxSize = preferredSize, networkType = networkType, verbose = verbose, indent = indent) 2: projectiveKMeans(datExpr, preferredSize = maxBlockSize, checkData = FALSE, sizePenaltyPower = blockSizePenaltyPower, nCenters = nPreclusteringCenters,  verbose = verbose - 2, indent = indent + 1)  
  > **username_0**: 1: blockwiseModules(B_CC_4, power = 6, TOMType = "signed", minModuleSize = 10,       reassignThreshold = 0, mergeCutHeight = 0.25, numericLabels = TRUE, pamRespectsDendro = FALSE, saveTOMs = TRUE, saveTOMFileBase = "PBCreponseTOMB",        verbose = 3)  
  > **username_0**: I can't add more of the sessionInfo() as too many characters.. can you let me know which parts are key to review. Thank you so much for your kind assistance. I am abit lost with the error and re-run over and over again and re-formatted my raw data, cant see any errors there, thank you  
  > **username_2**: @username_0 You can [edit] your question to include these details and other that might be needed to give a good answer to your question (And help future readers to find it, as comments are not indexed by searcher)  
  > **username_1**: Please try installing and using this development version of WGCNA: https://www.dropbox.com/s/fuu73li4ajjfr3z/WGCNA_1.67-90.tar.gz?dl=0 and see if it solves the issue. Thanks again for reporting the issue.  
  > **username_0**: Thank you kindly for all your kind help, very much appreciate it  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2019-05-04. Score: 2 | Accepted answer
  
  Looks like a bug in the code which I will try to hunt down and fix. In the meantime, I would suggest playing with maxBlockSize argument to blockwiseModules. Try increasing it as much as your available RAM allows (see the paragraph "A second word of caution concerning block size" on page 6 of [WGCNA tutorial I, section 2c](https://horvath.genetics.ucla.edu/html/CoexpressionNetwork/Rpackages/WGCNA/Tutorials/FemaleLiver-02-networkConstr-blockwise.pdf), for some guidance on how to set maxBlockSize). Hope this helps.
  
  > **Comments:**
  > **username_0**: Thank you so much for looking over this for me, I very much appreciate your time and effort. I will try and play around with the maxBlockSize as suggested. Thank you kindly  
  > **username_3**: I also got this error: Did you manage to solve the issue @username_1 > > sessionInfo() R version 3.5.1 (2018-07-02) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 7 x64 (build > 7601) Service Pack 1 > > Matrix products: default > > locale: [1] LC_COLLATE=English_New Zealand.1252 LC_CTYPE=English_New > Zealand.1252 LC_MONETARY=English_New Zealand.1252 [4] LC_NUMERIC=C > LC_TIME=English_New Zealand.1252 > > attached base packages: [1] stats graphics grDevices utils > datasets methods base > > other attached packages: [1] WGCNA_1.67 fastcluster_1.1.25 > dynamicTreeCut_1.63-  
  > **username_1**: Please try the newest version (1.68) of WGCNA from CRAN. This bug should be fixed.  
  
  ---
  
  