aboutsummaryrefslogtreecommitdiff
path: root/gn3/computations
diff options
context:
space:
mode:
authorPjotr Prins2024-04-03 12:26:35 +0200
committerFrederick Muriuki Muriithi2024-09-12 07:40:04 -0500
commite10b62f88432856019540074fd19b6acdb70d4ad (patch)
tree63dbd35a04d359229a69645f623d659ba1f37f4c /gn3/computations
parentfd25b6bf205e4642cf5f6ba5ed0e0cad73efc0b6 (diff)
downloadgenenetwork3-e10b62f88432856019540074fd19b6acdb70d4ad.tar.gz
Modify script paths so they can be edited in Guix
Diffstat (limited to 'gn3/computations')
-rw-r--r--gn3/computations/ctl.py2
-rw-r--r--gn3/computations/wgcna.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/gn3/computations/ctl.py b/gn3/computations/ctl.py
index f881410..eb34656 100644
--- a/gn3/computations/ctl.py
+++ b/gn3/computations/ctl.py
@@ -13,7 +13,7 @@ def call_ctl_script(data):
"""function to call ctl script"""
data["imgDir"] = TMPDIR
temp_file_name = dump_wgcna_data(data)
- cmd = compose_wgcna_cmd("ctl_analysis.R", temp_file_name)
+ cmd = compose_wgcna_cmd("scripts/ctl_analysis.R", temp_file_name)
cmd_results = run_cmd(cmd)
with open(temp_file_name, "r", encoding="utf-8") as outputfile:
diff --git a/gn3/computations/wgcna.py b/gn3/computations/wgcna.py
index c985491..01d024b 100644
--- a/gn3/computations/wgcna.py
+++ b/gn3/computations/wgcna.py
@@ -58,7 +58,7 @@ def process_image(image_loc: str) -> bytes:
def compose_wgcna_cmd(rscript_path: str, temp_file_path: str):
"""function to componse wgcna cmd"""
# (todo):issue relative paths to abs paths
- cmd = f"Rscript ./scripts/{rscript_path} {temp_file_path}"
+ cmd = f"Rscript scripts/{rscript_path} {temp_file_path}"
return cmd