diff options
author | Alexander Kabui | 2021-12-22 09:40:15 +0300 |
---|---|---|
committer | GitHub | 2021-12-22 09:40:15 +0300 |
commit | 27d54257735156ebc9d12f3ce638ea469d14e15e (patch) | |
tree | cf6ce655a8b3e8790571eec863bbec6c4cd84426 | |
parent | 65aeebd3bef1c3fe563226b1dd8222783ee405bf (diff) | |
download | genenetwork3-27d54257735156ebc9d12f3ce638ea469d14e15e.tar.gz |
Refactor wgcna (#63)
* add r as a gn3 input
* calculate powers from user input
* fix merge conflict
-rw-r--r-- | scripts/wgcna_analysis.R | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/scripts/wgcna_analysis.R b/scripts/wgcna_analysis.R index b0d25a9..d368013 100644 --- a/scripts/wgcna_analysis.R +++ b/scripts/wgcna_analysis.R @@ -25,6 +25,7 @@ if (length(args)==0) { inputData <- fromJSON(file = json_file_path) imgDir = inputData$TMPDIR +inputData trait_sample_data <- do.call(rbind, inputData$trait_sample_data) @@ -51,10 +52,8 @@ names(dataExpr) = inputData$trait_names # Allow multi-threading within WGCNA enableWGCNAThreads() -# choose softthreshhold (Calculate soft threshold) -# xtodo allow users to pass args - -powers <- c(c(1:10), seq(from = 12, to=20, by=2)) +# powers <- c(c(1:10), seq(from = 12, to=20, by=2)) +powers <- unlist(c(inputData$SoftThresholds)) sft <- pickSoftThreshold(dataExpr, powerVector = powers, verbose = 5) # check the power estimate |